function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

Bulk API batches hanging mysteriously or "unexpected error"

I was wondering how many people out there are coding using the Bulk API, and what your experiences have been... For me it's been a bit frustrating.  Batch processing is very inconsistent and (seemingly) temperamental.  The strangest of all has been the mysterious hangs of batches.  For example, right now I have a job currently consisting of four batches, each of 5000 Opportunity records.  The first three required between 3 and 4 minutes to process, while the fourth has been running now for five hours, but still says "In Progress" (and not timed out, etc. as you might expect), with 3700 complete.  The Processing Time information shows values below those of the prior three batches, so I know it's not actually doing anything, or having some type of trigger cascade, or whatever.  It's just sitting there...  Is there any way to get it running again?


I'd really like to rely on this feature for our data migration, but these runtime issues are pretty painful.


In addition, during deletes I sometimes will get an "unexpected error, contact support" message from a batch.  See case 03853809.


If anyone has advice or best practices for dealing with this I would be grateful to hear them.  FWIW I'm running from Perl via WWW::Salesforce::Simple and REST::Client, but this seems to be a server side issue.





Saif KaderSaif Kader
Hi Jeff - were you ever able to resolve this? We are seeing the same issue so was hoping you might have found a fix. Thanks
Wow, a blast from the past!  I did eventually use the Bulk API for our migration, but some preprocessing greatly aided in getting things running smoothly.  See my blog for details