My understanding is that due to governor limits, one cannot call @future methods directly from within a Batch Apex transaction (limit is 0), and only one Queueable Apex job can be enqueued per execution.
However, the documentation states that within a Queueable class transaction, one can call @future methods up to 50 times.
This implies that by chaining: Batch Class → Queueable Class → @future method, one could effectively call up to 50 @future methods from a Batch transaction.
Is my understanding correct?
https://developer.salesforce.com/docs/atlas.ja-jp.apexcode.meta/apexcode/apex_gov_limits.htm
3 réponses
Yes. Your Queueable is running it it's own context at a later date. The limits of the Queueable not it's launching batch should apply.