What is a CritSit?
It’s short for “Critical Situation”, and basically, it's when my red phone rings. It means I have to drop everything and jump on a plane because there is a SharePoint server somewhere in Europe, Middle East or Africa that needs my help.
Needless to say this is something we really want to try to avoid.
The interesting thing is, when I look back over the CritSit’s that I have responded to over the past year or so, a significant number of them follow this pattern:
This whole process might happen multiple times per day, or just once or twice per week. It is intermittent, so it's hard to reproduce, and often people just "live" with it.
Now, the reason it is hard to reproduce, and why it appears intermittent, is because the amount of load on the server has a big impact on how frequently it occurs. The more users on the system, the more frequently the SharePoint "crash" happens.
When I arrive onsite and find myself facing such an issue I usually start by doing the following:
In most cases I’m able to reproduce the problem fairly reliably. For example, I can say "Running test script X with 20 users for X minutes will always cause a 'crash'". At this point I typically remove the "Tree Navigation" control and re-run the script, only this time of course there is no crash, thereby proving the control is causing the issue.
With this testing complete, and our problem control identified we can look into it in more detail. Here there is also a pattern, in nearly every occasion the cause has been one of two things:
The good news is that we *finally* have a great whitepaper that describes, in detail ,some of the key code practices you should implement in order to avoid this type of issue, and therefore avoid a CRITSIT:
Best Practices: Using Disposable Windows SharePoint Services Objects
Of course, the other way of avoiding such issues is to ensure your code is fully tested, including complete load testing. It is incredibly important that you create an environment, with production data, that can be used to simulate the production load. This environment then allows you to develop baselines, which you can use to determine the overall impact of a particular customisation.
Anyway, take a look at the whitepaper, and good luck coding!
Written and posted using Microsoft Word 2007 Beta 2