nebula-logger-purging-and-retention
Installation
SKILL.md
Log Retention and Purging in Nebula Logger
The Retention Model
Every Log__c record has a LogRetentionDate__c. When that date passes, the log becomes eligible for purging by LogBatchPurger. The retention date is set at insert time on Log__c from a combination of:
LoggerSettings__c.DefaultNumberOfDaysToRetainLogs__con the effective hierarchy record.- Optionally,
LoggerScenarioRule__mdt.NumberOfDaysToRetainLogs__cwhen the log's scenario matches a scenario rule (scenario-specific overrides win over the hierarchy default).
If no retention days are configured, LogRetentionDate__c is left null and the log is never auto-purged.
LoggerSettings__c Retention Fields
The retention side of LoggerSettings__c is a hierarchy custom setting - values cascade org default -> profile -> user. The relevant fields: