You need to sign in to do that
Don't have an account?
Cody Bustamante 9
Cannot execute trigger: Apex CPU time limit exceeded.
I have a series of process builders that are routinely causing this error. I have already enabled: Query optimization in bulk mode. Is there a limit to the number of process builder that are recommended running at a single time or what can I do to help resolve this?
Here is one of the error messages I get frequently:
Cannot execute flow trigger: We can't save this record because the “Regional Territory Assignment” process failed. Give your Salesforce admin these details. This error occurred when the flow tried to update records: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY: DSCORGPKG.DiscoverOrgCustomMapping_Lead: System.LimitException: Apex CPU time limit exceeded. You can look up ExceptionCode values in the SOAP API Developer Guide. Error ID: 93739643-76958 (-820305936)
Here is one of the error messages I get frequently:
Cannot execute flow trigger: We can't save this record because the “Regional Territory Assignment” process failed. Give your Salesforce admin these details. This error occurred when the flow tried to update records: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY: DSCORGPKG.DiscoverOrgCustomMapping_Lead: System.LimitException: Apex CPU time limit exceeded. You can look up ExceptionCode values in the SOAP API Developer Guide. Error ID: 93739643-76958 (-820305936)
Good luck!
Thanks a ton for offering to help. To be honest I have no idea about any of this stuff. I started at my org about a year ago with no one to train me. I've gotten pretty good so far but there is still a ton of stuff I don't know about. We recently implemented a third party integration called DiscoverOrg but I'm not sure where I would find that code. And honestly, this isn't the only Process Builder error I'm getting. I'm getting a ton, but our SF subscription doesn't allow me dev support. I feel really overwhelmed with all of it.
Where might I find that APEX code?
Hi Cody, No problem! I know its hard starting out, especially when you're figuring it out on your own.
Since DiscoverOrg is a third party integration you would not be able to modify their code. Could you post a screenshot of your Process Builder? Looking at that could help solve the error.
Thanks
Sure, I'll post this one, then maybe after you help me review this one I can get my hands dirty on the other ones with this experience. There are 11 sets of criteria being evaluated. I'll just post an example, they are all pretty similar:
This process builder first evaluates if the industry is missing (a required field for our org once they get to a certain stage (MQL - Marketing Qualified) and then evaluates the next criteria
Then it looks at industry and routes the lead to either a "Channel" Governmentoverment" territory
Then finally it looks to states - if it doesn't match the above criteria then it looks to the state and assigns a regional territory:
There are 11 of these. I have another one I'm making that does this and changing lead status and lead owner all at the same time. That process builder has 25 criteria evaluation stages with as many as 45 logic filters in each. I'm wondering if these things are just too big.
One thing that helped a lot with my processes was to expand that Advanced arrow in the "Define Criteria for this Action Group" then check the box to only run the process when specified changes are made.
I do not see anything too crazy in your Process. If checking that box doesn't help you may need to contact support at DiscoverOrg. As you mentioned, you dont have access to SF Dev support, but this could be a DiscoverOrg issue, and they would be the ones to fix their code if needed.
Cody