Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
Commit Job Scheduling Transaction
- Resource
-
1COMMIT_JOB_SCHEDULING_TRANSACTION - Available version
- 55.0
- Request Parameters
-
Name Type Description Required or Optional jobChain String ID of the job chain record. Required jobId String ID of the job record for which scheduling transaction is to be started. Required - Apex Request Example
-
1// name of the salesorg for which the job should be scheduled 2String salesOrg = '0001'; 3<namespace>.JobSchedulingCommitCallout callout = new <namespace>.JobSchedulingCommitCallout(salesOrg); 4 5// Log Transaction Id 6String txId = <namespace>.TransactionHandler.getTransactionIdentifier(); 7 8// Job object 9<namespace>.Job job = new <namespace>.Job(); 10job.JobChainName = 'TPM_Calculation_Chain_<timestamp>'; 11job.JobName = 'PromotionCalculation'; 12 13<namespace>.OffplatformCalloutResponse response = callout.execute(txId, job); 14 15if (response.status != 200) { 16 // Handle error 17}