I talked about the usage of Salesforce BULK API in Talend Data Integration Studio and the Dell Boomi Integration Platform previously. So I’m wondering, how many of us really know that there are actually 2 concurrency modes available in the Salesforce BULK API – Serial mode and Parallel mode.
This is the default mode in the BULK API. Salesforce will process all the batches in a posted job in parallel and this gives you a better performance in uploading data. However, this might lead to lock contention which will cause the upload to fail.
Salesforce will process all the batches in a posted job one by one and this can help to prevent the lock contention issue that can be encountered in Parallel mode. But, please bear in mind that you should only use this mode if you couldn’t get around the lock contention issue.
You can enable this in Apex Data Loader settings as shown in the screenshot below.
You can set the concurrency mode in the job as the following:
JobInfo job = new JobInfo();
job = bulkConnection.createJob(job);
If you would like to know more information about concurrency mode in Salesforce BULK API, please visit the Bulk API Developer’s Guide: