Repository navigation
Handle DELETE_OPERATION_TOO_LARGE exception #1026
Description
Activity
Hi @manuerwin thanks for reporting this! The purge job doesn't directly handle deleting Feed Items, so the implicit deletion of those when deleting
LogEntry__cdata can cause this issue. I'll look at trying to improve the code to handle this better - in the meantime, you should be able to work around it by reducing the batch size, using the includedLoggerParameter__mdtrecordLogBatchPurgerDefaultBatchSize.- addedLayer: ConfigurationItems related to the custom hierarchy setting LoggerSettings__c or any included custom metadata typeItems related to the custom hierarchy setting LoggerSettings__c or any included custom metadata typeFeature: Log RetentionItems related to LogBatchPurger or LogBatchPurgeSchedulerItems related to LogBatchPurger or LogBatchPurgeScheduler
on Sep 9, 2026 Thanks @jongpie !!
Should have said I've already tried reducing the default (500) to 100 and still getting the error, will reduce further 🤞
IF I get some spare time 😛 will push a PROpened a fix in #1030 (currently a draft while I sort out an API permission quirk) —
LogBatchPurgernow falls back to partial deletes + recycle-bin emptying when the cascade delete throwsDELETE_OPERATION_TOO_LARGE, via a new virtualLoggerDataStore.Database.emptyRecycleBinfor mockability, with a regression test.Reacted by Manu
Package Edition of Nebula Logger
Unlocked Package
Package Version of Nebula Logger
v4.19.3
New Bug Summary
Periodically receive Apex unhandled exceptions during scheduled purge batch window that delete failed due to DELETE_OPERATION_TOO_LARGE, Cascade deleting too many records for both Feed Items and Log Entries.
The log records (and child log entries) are deleted by the time I review the unhandled exceptions.
IFF the eventual deletion of the parent logs is guaranteed, would be great to handle (WARN/ERROR log?) these currently unhandled exceptions.