Skip to content
June 20, 2011 / kiranpatils

Basics of Threshold exceeds


Our CM Server was performing bit slow. First we checked all the things (log files etc.). But nothing good we were able to find out. So, we decided to check few pages which might have some issue in rendering/sublayout/the way page has been built. To dig in to this issue we started reading something which should help us to do the same. We searched a bit and found “Threshold” functionality from Sitecore. We read some basics of it and enabled it. And we got so huge log files out of it and confused us which lead us to read more on it and understand it deeply. So, if you are also confused same as us then this post is for you!


Okay, let’s start with Basics. If you don’t know what is Threshold then please read following blog entry – Really very well explained!:

In short, there are three type of Thresholds:

Item Threshold : Related to total Item accessed.

Memory Threshold : Related to total memory consumed.

Timing Threshold : Related to total time consumed.

Okay you read this and open your Web.Config file and enable Threshold log entries (StopMeasurements and StartMeasurements are the key thing you should search for). Now, you go home and second day you come you go to your CM Server and see the log file, and it has been reached around 32 MB! And when you open it you find too many Threshold entries and when you start looking at those threshold entries sometime you get Images/Pages in Threshold log entries. You go to that images/pages and you find that they are normal.

Now, at this point of time you are confused about accuracy of the data provided (even we too was in same dilemma!). Okay so let me share our findings on it.

Basically the way this feature has been architect-ed it will not work on real production environment, as on real production environment you will have more than one requests served by a single request and it will lead us to inaccurate data.

Item, memory and timing thresholds in Sitecore only provide accurate data in testing scenarios with a single visitor accessing the site. These threshold warnings can be useful when evaluating the performance of a specific page when accessed by a single user. In production environments, however, when many people are accessing the site, these warnings reflect the activity of many users and, as a result, do not provide useful information from a performance monitoring perspective. As a result, Sitecore recommends disabling these warning messages so that log files do not  become unnecessarily cluttered.

This message appears in Sitecore logs due to the Sitecore architecture. Generally, such messages are very important in development and testing environment when tests are performed in single request mode. There is a single counter for measuring the number of accessed items. At the beginning of a request the value of the counter is stored and subtracted from the value of the same counter after finishing the item rendering. The result is the number of items accessed during the request. If two or more requests are handled simultaneously, accessing item attempts overlap and the number of accessed items may be incorrect. The same holds true for the memory and time threshold. However, when you are repeatedly confronted with such warnings for a particular page, this may indicate that you need to review its logic and perform a detailed investigation in the single request mode with special tools, such as Sitecore Debugger or smth. like dotTrace profiler

Source :

So, In short you should use Threshold on Local/Test environment and if you find any URLs which are exceeding thresholds then only you should investigate those items further. And always Disable Thresholds on production environment. How to do it? Above link explains it? and also below link is good to read:

Also, Feel free to modify your Threshold values on Local/Test environment as per your solution architecture.


Happy Threshold Debugging! 🙂



Leave a Comment
  1. Jens Mikkelsen / Aug 9 2011 1:58 am

    Hi Kiran,

    Nice post. Just as a remark I have actually had success debugging with threshold exceeds in production as well. Each Threshold exceed leaves a url in the log entry. Using a logparser i have made statistics of what URL most often reports an item exceed. This often leaves you with a few URL’s reporting very often. This is great for locating performance issues.
    Most often when I have done this I find the URL’s and often I see a descendant-or-self iterating the complete tree

    • kiranpatils / Aug 9 2011 9:37 pm

      Thanks Jens!

      Yes, It makes sense! Thanks for sharing your invaluable experience with us!

      Keep Visiting and Keep reading!

      Happy Coding! 🙂

      Kiran Patil


  1. Does your CM server performing slow? « Sitecore basics!
  2. Sitecore Troubleshooting Path | Sitecore basics!

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: