4

I have an Process Builder process that submits a records into a Approval Process. It only seems to work without error if I have no entry criteria. If I have any criteria added to the Process Builder besides "No Criteria-just execute action!" (and I've changed this to several different criteria that could be applicable to the approval process) I am given a workflow failed to trigger a flow error and the debug logs show:

An error occurred at element myRule_1_A1. Too many retries of batch save in the presence of Apex triggers with failures: when triggers are present partial save requires that some subset of rows save without any errors in order to avoid inconsistent side effects from those triggers. Number of retries: 2 .

Flow Details
Flow Name: Approval_Process_Training_Request
Type: Workflow
Version: 11
Status: ACTIVE

Flow Details
Start time(GMT): Wed Jul 15 15:51:35 GMT 2015
End time(GMT): Not Yet Finished
Duration: 2 seconds
Decision: myDecision
Submit for Approval: myRule_1_A1

Has anyone seen this error and how did you workaround it? Thank you in advance,

  • I have similar error "Too many retries of batch save in the presence of Apex triggers with failures: when triggers are present partial save requires that some subset of rows save without any errors in order to avoid inconsistent side effects from those triggers" when I try to fix the unit test after changes 2-step approval process into 5-step approval process – Patlatus Aug 25 '16 at 14:21
  • @patlatus At the time of this error, the approval process for my custom object was pretty simple. I was using Process Builder to auto-submit the record for approval. So, no triggers/unit tests were being used. I was never able to find the reason for the exception so now we just manually submit each record to the approval process. – Bailey Rudd Aug 26 '16 at 17:22
  • this error says that exists some additional error. Do you have any actions on record approval? Probably either when record is submitted for approval or when record is actually approved some other error happens, most probably some Governor limit error, which doesn't happen if you do it manually. I agree it would be hard to debug what actual error is causing Process Builder to fail, but you could at least try to read debug logs for more information, at least this worked for me – Patlatus Aug 27 '16 at 19:32
1

I had similar error "Too many retries of batch save in the presence of Apex triggers with failures: when triggers are present partial save requires that some subset of rows save without any errors in order to avoid inconsistent side effects from those triggers" when I try to fix the unit test after changes 2-step approval process into 5-step approval process.

Yesterday after deep investigation I have discovered that this error happens when you have another error in trigger, workflow, process builder or visual flow, any of which is triggered by approval process.

In my case trigger caused 101 SOQL DML Exception. So when I moved 4 approval process steps before Test.startTest statement and 1 approval process step after Test.startTest statement, the inner error has fixed and so the outer error disappeared.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.