Showing posts from November, 2010

Low effort, high impact

This is a bit off topic, but I’d like rant a bit about bottled water, of all things.  It has always seemed like bottled water was both an obvious marketing trick and a huge environmental disaster.   My impression has long been that corporations take what is basically tap water, and in some instances literally tap water, and sell it to us at hundreds or thousands of times the cost.  An obvious rip off.  Even worse it has to have an enormous negative environmental impact.  Manufacturing plastic, pumping, bottling, shipping, stocking, refrigerating and disposing, all for what?  For a convenient on-the-go disposable container?  Because it tastes fresher?  I’m not at the forefront of green initiatives, not by a long shot, but this one just seems so obvious that anyone who is and environmental advocate has to be enraged.  But it never seemed to bother anyone else.  Well, the other day I watched the documentary Tapped .  Finally, a comprehensive overview of the bottled water industry that c

The ViewState, the SessionPageStatePersister and the Memory Leak

  We recently encountered frequent performance degradation due to high memory utilization in our ASP.NET application.  I won’t go into the details of how we actually identified the source of the leak, unless there’s a considerable public outcry for such an explanation.  Suffice it to say that we were able to track it down with Windbg and a few essential blog posts (below).  In this case what we learned is more noteworthy than how we learned it.  What we found to be the cause of the memory leak was more or less a classic mistake, with a twist.  Deep in the bowels of a fairly complex page, nested several UserControls deep there lived a DropDownList control which was being assigned to ViewState.  That’s not a particularly good idea, but ordinarily that wouldn’t cause a memory leak, although it would create considerable ViewState bloat (if the DropDownList is even serializable which I never confirmed).  ViewState is serialized into gobbledygook and stuffed into a hidden field.  Howeve