UTIL_AsyncChain.StepResult
Class · Group: Async
Learn it: Fast Start - Async Processing and Async Processing guide
global inherited sharing class UTIL_AsyncChain.StepResultImmutable result object returned by each ChainStep to indicate success or failure. Use the static factory methods to create instances.
Example
UTIL_AsyncChain.StepResult result = UTIL_AsyncChain.succeeded('All records processed');
UTIL_AsyncChain.StepResult failure = UTIL_AsyncChain.failed('Missing required field');Properties
| Property | Description |
|---|---|
| global Object data | Optional payload data returned by the step. |
| global Exception error | The exception that caused the step to fail, if applicable. |
| global String message | Optional human-readable message describing the outcome. |
| global Boolean permanentFailure | True when the step declared this failure permanent: the failure will happen again on every try, so the chain refuses any retry whatever the configured retry budget, and records the failure with category StepException. |
| global Boolean success | Whether the step completed successfully. |
data
global Object dataType: Object
Optional payload data returned by the step.
error
global Exception errorType: Exception
The exception that caused the step to fail, if applicable.
message
global String messageType: String
Optional human-readable message describing the outcome.
permanentFailure
global Boolean permanentFailureType: Boolean
True when the step declared this failure permanent: the failure will happen again on every try, so the chain refuses any retry whatever the configured retry budget, and records the failure with category StepException. Never null: false on every result except one built by failedPermanently().
success
global Boolean successType: Boolean
Whether the step completed successfully.