QUESTION:
I am getting the following error when attempting to process a file in PeopleImport. How can I resolve?
2011-09-20T06:22:11-04:00,,"",,Insert,,,,," Message: MyLeadTrigger: System.LimitException: Too many future calls: 11 Status code: 13"
ANSWER:
- This type of error occurs when some type of custom APEX code (in this example a trigger called "MyLeadTrigger"), has not been properly optimized for batch processing.
- The same error would occur if you tried to insert/update the same groups of records via the Salesforce Data Loader.
- The trigger code will need to be updated to handle batch processing to avoid this error.
- There is some information on http://developer.force.com on how to optimize triggers. Search for "Too many future calls" for more information.
- Lowering the "Update/Insert Batch Size" setting in PeopleImport Options menu may also allow the processing to complete successfully (select the "Options" button lower left).
- The default setting is 100, but this can be set as low as 1
- Keep in mind that the smaller the batch size, the more API calls will be used per insert/update
- There is a limit imposed by Salesforce on how many API calls are allowed in a 24hr period.