Repository navigation
The AsyncActions.DuplicateBehavior Enum
GitHub Action edited this page Oct 9, 2026
·
1 revision
The AsyncActions.DuplicateBehavior enum sets what AsyncActions.groupByRecord does when two actions in a batch name the same record.
AsyncActions.DuplicateBehavior behavior = AsyncActions.DuplicateBehavior.FAIL_DUPLICATES;
Map<Id, AsyncActions.RecordGroup> groups = AsyncActions.groupByRecord(settings, actions, behavior);| Value | Description |
|---|---|
GROUP_DUPLICATES |
The default. Every action for the record joins one group and gets the same outcome. Use it when an action means only "process this record". |
FAIL_DUPLICATES |
Keeps the first action for the record, and fails the rest with SUDDEN_DEATH. Actions with no related record are never duplicates. Use it when actions for one record store different Data__c, since grouping would treat them as one request. |
- AsyncAction__c
- AsyncActionProcessor__mdt
- AsyncActionParameter__mdt
- AsyncActionScheduledJob__mdt
- AsyncActionScheduledJobItem__mdt