Are some Apex governor limits are becoming “softer”?Detecting governor limits through apexGovernor limits on http calloutsManaged packages governor limitsGovernor Limits Across Object TriggersWhat governor limits impact Apex Describe methods?Does execute anonymous from Developer Console not enforce heap size limit?How Aggregate Result are count against the Governor Limits?What are the governor limits for the SandboxPostCopy Interface?Governor Limits on Salesforce Government CloudMap / Trigger / Governor limits

The Target Principal Name Is Incorrect. Cannot Generate SSPI Context (SQL or AD Issue)?

Why do some games show lights shine thorugh walls?

Require advice on power conservation for backpacking trip

Why do all the teams that I have worked with always finish a sprint without completion of all the stories?

C-152 carb heat on before landing in hot weather?

Vanishing of certain coefficients coming from Coxeter groups

Has there been any indication at all that further negotiation between the UK and EU is possible?

Is adding a new player (or players) a DM decision, or a group decision?

Cascading Repair Costs following Blown Head Gasket on a 2004 Subaru Outback

Why is C++ initial allocation so much larger than C's?

Is it possible writing coservation of relativistic energy in this naive way?

How risky is real estate?

Employer wants to use my work email account after I quit

Why did pressing the joystick button spit out keypresses?

Is it damaging to turn off a small fridge for two days every week?

Does this Wild Magic result affect the sorcerer or just other creatures?

How to get cool night-vision without lame drawbacks?

How does a blind passenger not die, if driver becomes unconscious

Can humans ever directly see a few photons at a time? Can a human see a single photon?

“D’entre eux” to mean “of them”

A STL-like vector implementation in C++

Archery in modern conflicts

Can any NP-Complete Problem be solved using at most polynomial space (but while using exponential time?)

What are the penalties for overstaying in USA?



Are some Apex governor limits are becoming “softer”?


Detecting governor limits through apexGovernor limits on http calloutsManaged packages governor limitsGovernor Limits Across Object TriggersWhat governor limits impact Apex Describe methods?Does execute anonymous from Developer Console not enforce heap size limit?How Aggregate Result are count against the Governor Limits?What are the governor limits for the SandboxPostCopy Interface?Governor Limits on Salesforce Government CloudMap / Trigger / Governor limits






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








7















Im currently updating lots of records of an SObject having extensive trigger logic and today I've noticed this limit consumption:



Limit Name .................... ┃ ...Actual ┃ ....Maximal ┃ ....Usage 
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HeapSize....................... ┃ 8'254'161 ┃ ..6'000'000 ┃ ..137.57%
CpuTime........................ ┃ ....8'061 ┃ .....10'000 ┃ ...80.61%
DmlStatements.................. ┃ ........2 ┃ ........150 ┃ ....1.33%
DmlRows........................ ┃ ....3'550 ┃ .....10'000 ┃ ...35.50%
Queries........................ ┃ .......40 ┃ ........100 ┃ ...40.00%
QueryRows...................... ┃ ....5'664 ┃ .....50'000 ┃ ...11.33%
EmailInvocations............... ┃ ........1 ┃ .........10 ┃ ...10.00%


So far, my understanding was that the 6MB limit for HeapSize is strict. Now it seems, that salesforce is tolerating some kind of exceeding since > 8MB was executed without exception.



Does anyone of you had similar experiences? If so, for which limit and how much of over consumption has worked for you? Is it reliable or random? Or is there any kind of documentation for this I haven't noticed? Of course more heap would be wonderful!










share|improve this question
























  • My understanding is that the limits are not always enforced but may be enforced so code should be tuned to stay within them. Will be interested to see if anyone can explain why this is.

    – Keith C
    Jun 14 at 8:54











  • @KeithC Wild guess: they are test driving the impact of higher limits to their server performance. But would be nice to get some feedback.

    – Uwe Heim
    Jun 14 at 9:17












  • I know there was at least one Dreamforce/Trailhead DX session that covered Salesforce's plans to move to a different enforcement model for governor limits, but I don't know if heap size was among the governor limits discussed. I'll try to find a video of the session.

    – Derek F
    Jun 14 at 13:22

















7















Im currently updating lots of records of an SObject having extensive trigger logic and today I've noticed this limit consumption:



Limit Name .................... ┃ ...Actual ┃ ....Maximal ┃ ....Usage 
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HeapSize....................... ┃ 8'254'161 ┃ ..6'000'000 ┃ ..137.57%
CpuTime........................ ┃ ....8'061 ┃ .....10'000 ┃ ...80.61%
DmlStatements.................. ┃ ........2 ┃ ........150 ┃ ....1.33%
DmlRows........................ ┃ ....3'550 ┃ .....10'000 ┃ ...35.50%
Queries........................ ┃ .......40 ┃ ........100 ┃ ...40.00%
QueryRows...................... ┃ ....5'664 ┃ .....50'000 ┃ ...11.33%
EmailInvocations............... ┃ ........1 ┃ .........10 ┃ ...10.00%


So far, my understanding was that the 6MB limit for HeapSize is strict. Now it seems, that salesforce is tolerating some kind of exceeding since > 8MB was executed without exception.



Does anyone of you had similar experiences? If so, for which limit and how much of over consumption has worked for you? Is it reliable or random? Or is there any kind of documentation for this I haven't noticed? Of course more heap would be wonderful!










share|improve this question
























  • My understanding is that the limits are not always enforced but may be enforced so code should be tuned to stay within them. Will be interested to see if anyone can explain why this is.

    – Keith C
    Jun 14 at 8:54











  • @KeithC Wild guess: they are test driving the impact of higher limits to their server performance. But would be nice to get some feedback.

    – Uwe Heim
    Jun 14 at 9:17












  • I know there was at least one Dreamforce/Trailhead DX session that covered Salesforce's plans to move to a different enforcement model for governor limits, but I don't know if heap size was among the governor limits discussed. I'll try to find a video of the session.

    – Derek F
    Jun 14 at 13:22













7












7








7


1






Im currently updating lots of records of an SObject having extensive trigger logic and today I've noticed this limit consumption:



Limit Name .................... ┃ ...Actual ┃ ....Maximal ┃ ....Usage 
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HeapSize....................... ┃ 8'254'161 ┃ ..6'000'000 ┃ ..137.57%
CpuTime........................ ┃ ....8'061 ┃ .....10'000 ┃ ...80.61%
DmlStatements.................. ┃ ........2 ┃ ........150 ┃ ....1.33%
DmlRows........................ ┃ ....3'550 ┃ .....10'000 ┃ ...35.50%
Queries........................ ┃ .......40 ┃ ........100 ┃ ...40.00%
QueryRows...................... ┃ ....5'664 ┃ .....50'000 ┃ ...11.33%
EmailInvocations............... ┃ ........1 ┃ .........10 ┃ ...10.00%


So far, my understanding was that the 6MB limit for HeapSize is strict. Now it seems, that salesforce is tolerating some kind of exceeding since > 8MB was executed without exception.



Does anyone of you had similar experiences? If so, for which limit and how much of over consumption has worked for you? Is it reliable or random? Or is there any kind of documentation for this I haven't noticed? Of course more heap would be wonderful!










share|improve this question
















Im currently updating lots of records of an SObject having extensive trigger logic and today I've noticed this limit consumption:



Limit Name .................... ┃ ...Actual ┃ ....Maximal ┃ ....Usage 
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HeapSize....................... ┃ 8'254'161 ┃ ..6'000'000 ┃ ..137.57%
CpuTime........................ ┃ ....8'061 ┃ .....10'000 ┃ ...80.61%
DmlStatements.................. ┃ ........2 ┃ ........150 ┃ ....1.33%
DmlRows........................ ┃ ....3'550 ┃ .....10'000 ┃ ...35.50%
Queries........................ ┃ .......40 ┃ ........100 ┃ ...40.00%
QueryRows...................... ┃ ....5'664 ┃ .....50'000 ┃ ...11.33%
EmailInvocations............... ┃ ........1 ┃ .........10 ┃ ...10.00%


So far, my understanding was that the 6MB limit for HeapSize is strict. Now it seems, that salesforce is tolerating some kind of exceeding since > 8MB was executed without exception.



Does anyone of you had similar experiences? If so, for which limit and how much of over consumption has worked for you? Is it reliable or random? Or is there any kind of documentation for this I haven't noticed? Of course more heap would be wonderful!







apex governorlimits






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jun 14 at 8:32







Uwe Heim

















asked Jun 14 at 8:20









Uwe HeimUwe Heim

22.1k7 gold badges64 silver badges190 bronze badges




22.1k7 gold badges64 silver badges190 bronze badges












  • My understanding is that the limits are not always enforced but may be enforced so code should be tuned to stay within them. Will be interested to see if anyone can explain why this is.

    – Keith C
    Jun 14 at 8:54











  • @KeithC Wild guess: they are test driving the impact of higher limits to their server performance. But would be nice to get some feedback.

    – Uwe Heim
    Jun 14 at 9:17












  • I know there was at least one Dreamforce/Trailhead DX session that covered Salesforce's plans to move to a different enforcement model for governor limits, but I don't know if heap size was among the governor limits discussed. I'll try to find a video of the session.

    – Derek F
    Jun 14 at 13:22

















  • My understanding is that the limits are not always enforced but may be enforced so code should be tuned to stay within them. Will be interested to see if anyone can explain why this is.

    – Keith C
    Jun 14 at 8:54











  • @KeithC Wild guess: they are test driving the impact of higher limits to their server performance. But would be nice to get some feedback.

    – Uwe Heim
    Jun 14 at 9:17












  • I know there was at least one Dreamforce/Trailhead DX session that covered Salesforce's plans to move to a different enforcement model for governor limits, but I don't know if heap size was among the governor limits discussed. I'll try to find a video of the session.

    – Derek F
    Jun 14 at 13:22
















My understanding is that the limits are not always enforced but may be enforced so code should be tuned to stay within them. Will be interested to see if anyone can explain why this is.

– Keith C
Jun 14 at 8:54





My understanding is that the limits are not always enforced but may be enforced so code should be tuned to stay within them. Will be interested to see if anyone can explain why this is.

– Keith C
Jun 14 at 8:54













@KeithC Wild guess: they are test driving the impact of higher limits to their server performance. But would be nice to get some feedback.

– Uwe Heim
Jun 14 at 9:17






@KeithC Wild guess: they are test driving the impact of higher limits to their server performance. But would be nice to get some feedback.

– Uwe Heim
Jun 14 at 9:17














I know there was at least one Dreamforce/Trailhead DX session that covered Salesforce's plans to move to a different enforcement model for governor limits, but I don't know if heap size was among the governor limits discussed. I'll try to find a video of the session.

– Derek F
Jun 14 at 13:22





I know there was at least one Dreamforce/Trailhead DX session that covered Salesforce's plans to move to a different enforcement model for governor limits, but I don't know if heap size was among the governor limits discussed. I'll try to find a video of the session.

– Derek F
Jun 14 at 13:22










2 Answers
2






active

oldest

votes


















7














Back at Dreamforce '17, there was a session that outlined Salesforce's plans to restructure how governor limits worked.



The link to the video (for however long it'll be valid) is https://www.youtube.com/watch?v=0wHRmS1j3r4



The talk about "Reimagining Limits" begins at about 19:22 of the video, and heap size is included.



The "Cliff's Notes" for the presentation are:



  • Salesforce re-evaluates their strategies and approaches from time to time

  • And now it's time to re-evaluate limits

  • Salesforce wants to remove some limits, and make others be "thresholds" that are enforced based on how much activity is on your pod, how far you exceed the threshold, and how often you exceed the threshold

  • CPU, Heap, Database, and Concurrent Transactions are all explicitly mentioned as being targets for the new "thresholds" approach

  • There is a base threshold, and we're allowed to exceed that by some unknown % which is tied to activity on your pod

  • 24:35 of the video goes into some good examples of what Salesforce may look for when enforcing/notifying about thresholds (one time, under enforcement threshold => no notification. Multiple days just over the threshold => get notified to improve yer code)

  • This was supposed to be fully rolled-out in Summer '18 (i.e. one year ago)





share|improve this answer






























    0














    The way heap limits appear to be enforced often allows you to break it without any consequence but obviously probably not good practice to rely on this. I would be looking to assign null to any references to objects that you don't need anymore to try and reduce usage below the limit or cut your volume if not possible.



    You can also overrun the CPU limit a bit but this is much more likely to cause an exception. Think most of the other limits don't have any flex. Not seen any changes in how these have worked for last few years but you never know.






    share|improve this answer

























      Your Answer








      StackExchange.ready(function()
      var channelOptions =
      tags: "".split(" "),
      id: "459"
      ;
      initTagRenderer("".split(" "), "".split(" "), channelOptions);

      StackExchange.using("externalEditor", function()
      // Have to fire editor after snippets, if snippets enabled
      if (StackExchange.settings.snippets.snippetsEnabled)
      StackExchange.using("snippets", function()
      createEditor();
      );

      else
      createEditor();

      );

      function createEditor()
      StackExchange.prepareEditor(
      heartbeatType: 'answer',
      autoActivateHeartbeat: false,
      convertImagesToLinks: false,
      noModals: true,
      showLowRepImageUploadWarning: true,
      reputationToPostImages: null,
      bindNavPrevention: true,
      postfix: "",
      imageUploader:
      brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
      contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
      allowUrls: true
      ,
      onDemand: true,
      discardSelector: ".discard-answer"
      ,immediatelyShowMarkdownHelp:true
      );



      );













      draft saved

      draft discarded


















      StackExchange.ready(
      function ()
      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsalesforce.stackexchange.com%2fquestions%2f265975%2fare-some-apex-governor-limits-are-becoming-softer%23new-answer', 'question_page');

      );

      Post as a guest















      Required, but never shown

























      2 Answers
      2






      active

      oldest

      votes








      2 Answers
      2






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      7














      Back at Dreamforce '17, there was a session that outlined Salesforce's plans to restructure how governor limits worked.



      The link to the video (for however long it'll be valid) is https://www.youtube.com/watch?v=0wHRmS1j3r4



      The talk about "Reimagining Limits" begins at about 19:22 of the video, and heap size is included.



      The "Cliff's Notes" for the presentation are:



      • Salesforce re-evaluates their strategies and approaches from time to time

      • And now it's time to re-evaluate limits

      • Salesforce wants to remove some limits, and make others be "thresholds" that are enforced based on how much activity is on your pod, how far you exceed the threshold, and how often you exceed the threshold

      • CPU, Heap, Database, and Concurrent Transactions are all explicitly mentioned as being targets for the new "thresholds" approach

      • There is a base threshold, and we're allowed to exceed that by some unknown % which is tied to activity on your pod

      • 24:35 of the video goes into some good examples of what Salesforce may look for when enforcing/notifying about thresholds (one time, under enforcement threshold => no notification. Multiple days just over the threshold => get notified to improve yer code)

      • This was supposed to be fully rolled-out in Summer '18 (i.e. one year ago)





      share|improve this answer



























        7














        Back at Dreamforce '17, there was a session that outlined Salesforce's plans to restructure how governor limits worked.



        The link to the video (for however long it'll be valid) is https://www.youtube.com/watch?v=0wHRmS1j3r4



        The talk about "Reimagining Limits" begins at about 19:22 of the video, and heap size is included.



        The "Cliff's Notes" for the presentation are:



        • Salesforce re-evaluates their strategies and approaches from time to time

        • And now it's time to re-evaluate limits

        • Salesforce wants to remove some limits, and make others be "thresholds" that are enforced based on how much activity is on your pod, how far you exceed the threshold, and how often you exceed the threshold

        • CPU, Heap, Database, and Concurrent Transactions are all explicitly mentioned as being targets for the new "thresholds" approach

        • There is a base threshold, and we're allowed to exceed that by some unknown % which is tied to activity on your pod

        • 24:35 of the video goes into some good examples of what Salesforce may look for when enforcing/notifying about thresholds (one time, under enforcement threshold => no notification. Multiple days just over the threshold => get notified to improve yer code)

        • This was supposed to be fully rolled-out in Summer '18 (i.e. one year ago)





        share|improve this answer

























          7












          7








          7







          Back at Dreamforce '17, there was a session that outlined Salesforce's plans to restructure how governor limits worked.



          The link to the video (for however long it'll be valid) is https://www.youtube.com/watch?v=0wHRmS1j3r4



          The talk about "Reimagining Limits" begins at about 19:22 of the video, and heap size is included.



          The "Cliff's Notes" for the presentation are:



          • Salesforce re-evaluates their strategies and approaches from time to time

          • And now it's time to re-evaluate limits

          • Salesforce wants to remove some limits, and make others be "thresholds" that are enforced based on how much activity is on your pod, how far you exceed the threshold, and how often you exceed the threshold

          • CPU, Heap, Database, and Concurrent Transactions are all explicitly mentioned as being targets for the new "thresholds" approach

          • There is a base threshold, and we're allowed to exceed that by some unknown % which is tied to activity on your pod

          • 24:35 of the video goes into some good examples of what Salesforce may look for when enforcing/notifying about thresholds (one time, under enforcement threshold => no notification. Multiple days just over the threshold => get notified to improve yer code)

          • This was supposed to be fully rolled-out in Summer '18 (i.e. one year ago)





          share|improve this answer













          Back at Dreamforce '17, there was a session that outlined Salesforce's plans to restructure how governor limits worked.



          The link to the video (for however long it'll be valid) is https://www.youtube.com/watch?v=0wHRmS1j3r4



          The talk about "Reimagining Limits" begins at about 19:22 of the video, and heap size is included.



          The "Cliff's Notes" for the presentation are:



          • Salesforce re-evaluates their strategies and approaches from time to time

          • And now it's time to re-evaluate limits

          • Salesforce wants to remove some limits, and make others be "thresholds" that are enforced based on how much activity is on your pod, how far you exceed the threshold, and how often you exceed the threshold

          • CPU, Heap, Database, and Concurrent Transactions are all explicitly mentioned as being targets for the new "thresholds" approach

          • There is a base threshold, and we're allowed to exceed that by some unknown % which is tied to activity on your pod

          • 24:35 of the video goes into some good examples of what Salesforce may look for when enforcing/notifying about thresholds (one time, under enforcement threshold => no notification. Multiple days just over the threshold => get notified to improve yer code)

          • This was supposed to be fully rolled-out in Summer '18 (i.e. one year ago)






          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Jun 14 at 13:55









          Derek FDerek F

          21.8k5 gold badges24 silver badges53 bronze badges




          21.8k5 gold badges24 silver badges53 bronze badges























              0














              The way heap limits appear to be enforced often allows you to break it without any consequence but obviously probably not good practice to rely on this. I would be looking to assign null to any references to objects that you don't need anymore to try and reduce usage below the limit or cut your volume if not possible.



              You can also overrun the CPU limit a bit but this is much more likely to cause an exception. Think most of the other limits don't have any flex. Not seen any changes in how these have worked for last few years but you never know.






              share|improve this answer



























                0














                The way heap limits appear to be enforced often allows you to break it without any consequence but obviously probably not good practice to rely on this. I would be looking to assign null to any references to objects that you don't need anymore to try and reduce usage below the limit or cut your volume if not possible.



                You can also overrun the CPU limit a bit but this is much more likely to cause an exception. Think most of the other limits don't have any flex. Not seen any changes in how these have worked for last few years but you never know.






                share|improve this answer

























                  0












                  0








                  0







                  The way heap limits appear to be enforced often allows you to break it without any consequence but obviously probably not good practice to rely on this. I would be looking to assign null to any references to objects that you don't need anymore to try and reduce usage below the limit or cut your volume if not possible.



                  You can also overrun the CPU limit a bit but this is much more likely to cause an exception. Think most of the other limits don't have any flex. Not seen any changes in how these have worked for last few years but you never know.






                  share|improve this answer













                  The way heap limits appear to be enforced often allows you to break it without any consequence but obviously probably not good practice to rely on this. I would be looking to assign null to any references to objects that you don't need anymore to try and reduce usage below the limit or cut your volume if not possible.



                  You can also overrun the CPU limit a bit but this is much more likely to cause an exception. Think most of the other limits don't have any flex. Not seen any changes in how these have worked for last few years but you never know.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Jun 14 at 18:23









                  Kevin JonesKevin Jones

                  213 bronze badges




                  213 bronze badges



























                      draft saved

                      draft discarded
















































                      Thanks for contributing an answer to Salesforce Stack Exchange!


                      • Please be sure to answer the question. Provide details and share your research!

                      But avoid


                      • Asking for help, clarification, or responding to other answers.

                      • Making statements based on opinion; back them up with references or personal experience.

                      To learn more, see our tips on writing great answers.




                      draft saved


                      draft discarded














                      StackExchange.ready(
                      function ()
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsalesforce.stackexchange.com%2fquestions%2f265975%2fare-some-apex-governor-limits-are-becoming-softer%23new-answer', 'question_page');

                      );

                      Post as a guest















                      Required, but never shown





















































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown

































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown







                      Popular posts from this blog

                      Category:9 (number) SubcategoriesMedia in category "9 (number)"Navigation menuUpload mediaGND ID: 4485639-8Library of Congress authority ID: sh85091979ReasonatorScholiaStatistics

                      Circuit construction for execution of conditional statements using least significant bitHow are two different registers being used as “control”?How exactly is the stated composite state of the two registers being produced using the $R_zz$ controlled rotations?Efficiently performing controlled rotations in HHLWould this quantum algorithm implementation work?How to prepare a superposed states of odd integers from $1$ to $sqrtN$?Why is this implementation of the order finding algorithm not working?Circuit construction for Hamiltonian simulationHow can I invert the least significant bit of a certain term of a superposed state?Implementing an oracleImplementing a controlled sum operation

                      Magento 2 “No Payment Methods” in Admin New OrderHow to integrate Paypal Express Checkout with the Magento APIMagento 1.5 - Sales > Order > edit order and shipping methods disappearAuto Invoice Check/Money Order Payment methodAdd more simple payment methods?Shipping methods not showingWhat should I do to change payment methods if changing the configuration has no effects?1.9 - No Payment Methods showing upMy Payment Methods not Showing for downloadable/virtual product when checkout?Magento2 API to access internal payment methodHow to call an existing payment methods in the registration form?