We call the following endpoint at the same time each day to get a count of our daily async executions to track our usage.
/services/data/v50.0/limits
The following response gives us the # of daily async executions like so:
"DailyAsyncApexExecutions" : {
"Max" : 486000,
"Remaining" : 470645
}
I noticed on days we deploy to production, that our number shoots considerably higher (600% more executions). I'm just looking for an explanation to why and whether we need to consider this when looking at the limit and how close we generally are to it.
We run our tests/validate the package a day or two before actual deployment (then use quick deploy) so it doesn't seem to be the tests (likewise, I see that tests that run for a deployment run synchronously).
My only hunch is that Salesforce holds transactions that are occurring when the deployment tries to deploy and runs them async after the deployment is complete? In which case, I presume the increase depends on the activity level of the org while you're trying to deploy.
Questions:
- For deployments, is there expected to be a large increase in async apex execution?
- If it's expected, do we need to take this into consideration with our daily usage and how close we are to the limit?