Release 1 in development, 16 of 16 sprints done. Early access is open. 16 of 16 sprints done · Join early accessJoin early access

Purge Run

The Purge Run object logs one admin-requested purge of closed intervals older than a retention window, with Retention Days, Cutoff Date, Status, and the counts archived and deleted. The CSV export is attached as a file. Commonly used to audit what left the org and when.

API name: Purge_Run__c

Field API name Type Description
Archived Count Archived_Count__c Number (9, 0) How many Intervals this run copied to the Interval Archive big object, a whole number. Starts at 0 and grows with each chunk while the archive is on; stays 0 when it is off. Written by each chunk with the deleted count, so a run that stops part-way still shows what it archived, and set again when the run finishes. Shown on the Retention and purge screen of Sojourn Settings.
Help text: Stays copied to the Interval Archive by this run, set by Sojourn. 0 when the archive is off.
Cutoff Date Cutoff_Date__c DateTime The moment that set the scope of the run's org window: midnight, in the org's time zone, Retention Days before the day the run started. Closed, summarised Intervals of every object on the org's retention that ended before it were in scope; later ones were kept. A Tracked object with its own retention days has its own cutoff, and one set to Keep everything has none; the run's Message names each window. Set by Sojourn when the run starts.
Help text: Intervals on the org's retention that ended before this moment were in scope for this purge; objects with their own window are named in Message. Set by Sojourn.
Deleted Count Deleted_Count__c Number (9, 0) How many Intervals this run deleted, a whole number. Starts at 0 and grows with each chunk that archived (when on), saved its CSV file, and deleted its Intervals, all or none. Written by each chunk, so a run that stops part-way still shows what it deleted, and set again when the run finishes. Compare it with Interval Count to see whether the run reached everything in scope.
Help text: Stays deleted by this run, after they were archived (when on) and saved as CSV. Set by Sojourn.
Interval Count Interval_Count__c Number (9, 0) How many Intervals the run set out to purge: closed, summarised, and ended before their object's cutoff, counted once when the run started across every window, the number the typed confirmation of Purge now shows. A whole number. Deleted Count says how many went; the two differ when purge was turned off or the plan changed during the run, a chunk failed, a window could not start, an object's retention changed, or Intervals changed meanwhile.
Help text: Stays in scope when the run started. Compare it with Deleted Count.
Message Message__c LongTextArea (32768) The run's result in words, written by Sojourn when the run finishes. A complete run says how many Intervals were deleted in all and in each window (the org's days, and each group of Tracked objects with days of their own), which objects keep everything, how many Day summary rows older than Summary Rollup Days were removed (Month rows are kept), and whether purge was turned off or the org moved to the Free plan during the run. A failed run says what stopped it: a chunk, of which nothing was deleted, or a window that could not start, whose Intervals are kept. Blank while the run is queued or running.
Help text: The run's result, written by Sojourn: what it deleted, or why it stopped.
Requested By Requested_By__c Lookup (User) The user who started the run: the admin who chose Purge now, or for the nightly purge the user the Summaries job runs as. A lookup to User, set by Sojourn when the run starts. Shown on the Retention and purge screen of Sojourn Settings, so you can see who deleted what and when.
Help text: The admin who chose Purge now, or the user the nightly job runs as. Set by Sojourn.
Retention Days Retention_Days__c Number (5, 0) The org's retention window this run used, in days: the Purge Retention Days setting when the run started, a whole number from 30 to 3650. The cutoff is midnight that many days before the run's day. It applies to every object on the org's retention; a Tracked object with its own days, or Keep everything, is named in the run's Message instead. Set by Sojourn when the run starts; a later change to the setting does not change it.
Help text: The org's retention window this run used: closed Intervals older than this many days were archived (when on), saved as CSV, and deleted, except for objects with their own window.
Status Status__c Picklist: Queued, Running, Complete, Failed Where the run stands. One of Queued (the default, when the run is created), Running (set by each chunk), Complete (every chunk succeeded), or Failed (a chunk could not be saved, and nothing in that chunk was deleted, or the next window's batch could not start, and its Intervals are kept; the reason is in Message). Set by Sojourn. Only one purge runs at a time.
Help text: Running while the purge works through its chunks; Failed, with the reason in Message, when a chunk could not be saved or the next window could not start.