1

So i was checking the documentation of Queuable jobs, but I don't clearly understand the relationship between govern limits and every job that you can chain or create.

My first question is, considering that in every transaction you are up to 100 callouts, it means that every new job I create its a new transaction itself?, and it reboots the governor limits for this new job? Does that mean, that i would be able to do 100callouts for every Job?

Thanks in advance!

1
  • Consider accepting this as the answer if it answers your questions.
    – Rohit
    Commented Mar 3, 2023 at 14:31

1 Answer 1

3

Your confusion is due to your understanding of Apex Transaction. When you will consider each instance of queuable job as a single transaction, all limits will be clear to you.

Please find below answers :

  1. considering that in every transaction you are up to 100 callouts, it means that every new job I create its a new transaction itself?
  • Yes , every call to System.enqueueJob(new AsyncExecutionExample()); is a new transaction.
  1. it reboots the governor limits for this new job?
  • Yes , if by new job you mean call to System.enqueueJob(new AsyncExecutionExample())
  1. Does that mean, that i would be able to do 100 callouts?
  • Yes , 100 callouts per Apex transaction. Please refer Apex transaction definition here

Apex Governor limits : https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_gov_limits.htm

2
  • Thank you @rohit, you made it clear! I was a lit bit confused about apex transaction! Have a good day! Commented Mar 3, 2023 at 15:49
  • Thank you accepting as the answer !
    – Rohit
    Commented Mar 3, 2023 at 15:51

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .