We’ll start with binding data to the Grid View, then build up functionality from there.
First, we’ll implement a method to databind the Grid View, which will be called whenever databinding needs to be performed.
In Share Point 2010, the query-throttling feature is designed to prevent this problem – this will cut off large queries once a threshold has been passed and the full results will not be returned, thus safeguarding stability.
So first off we need ourselves a function to reset all of the Then we need to actually make sure this gets executed.
The problem here is that the Site Contents is rendered on-the-fly using Java Script so we have to resort to a little Script on Demand to get this working.
publishing portal) added this to the home page for you, thus triggering the problem without explicit configuration.
In large sites this would result in a significant query which put significant load on the servers, and the built-in caching didn’t fully mitigate it.
Although us architects/developers think that we know a lot about scaling Share Point these days, consider that in the 2007 release a common cause of Out Of Memory exceptions in large farms was use of the Content Query Web Part on site home pages, left to default settings.