Each extension in extension list listed more than 1 time

Topics: Business Logic Layer
Dec 29, 2010 at 12:07 AM

Hi.

i don't know why it is happening, but sometime my blog start hanging (this problem is not topic of this post) and it seems to be that apppool is recycling, and after this  each extension is listed > than 1 time in extensions list.

Have anybody stumble with this problem any time? I am running 2.0.0.29 version.

Coordinator
Dec 29, 2010 at 1:10 AM

That has been reported before ... even going back to BE 1.6.  Unfortunately, it appears the problem still exists.  I personally haven't been able to reproduce it, which is why I haven't looked into it very deeply.  If you restart your blog, by making any change to the web.config file (add a space, etc), that should clear it up so the Extensions are only listed once.

Where is your blog hosted, btw?  GoDaddy, or some other shared webhost?  Just curious.

Dec 29, 2010 at 8:26 AM

Yes you are right, when restarting pool - it is ok, or even when doing some changes in the Extensions it is ok also. I was take a look in the code and when you are doing some changes to Extensions it is cleaning collection which was in cache and put it there refreshed collection. So i think the problem is in collection which is in cache, some how data putted more than 1 time there.

Hosting I am using DiscountAsp for 3 days - server in Europe, and i don't know yet do i like it or no. For example i have put a loggin about restartiing apppool 10 hours ago and for now i have such not good statistics:

*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
Date: 12/29/2010 1:17:24 AM
Contents Below
Application_Start
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
Date: 12/29/2010 1:22:51 AM
Contents Below
Application_Start
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
Date: 12/29/2010 2:50:06 AM
Contents Below
Application_Start
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
Date: 12/29/2010 3:18:19 AM
Contents Below
Application_Start
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
Date: 12/29/2010 4:20:11 AM
Contents Below
Application_Start
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
Date: 12/29/2010 5:20:19 AM
Contents Below
Application_Start
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
Date: 12/29/2010 7:20:19 AM
Contents Below
Application_Start
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
Date: 12/29/2010 7:50:22 AM
Contents Below
Application_Start
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

 

Dec 29, 2010 at 11:07 AM

Well, about recycle app pool i have contacted to provider and they give me this info

Windows Server 2008/IIS 7:

* Idle timeout set to 20 minutes. (Information is NOT logged)
* Memory threshold set to 200 MB.
* CPU limit set to 70% utilization over 300 seconds (5 minutes).

So it seems that recycle app pool was by idle timeout.

About extensions  - i have change code for now in ExtensionManager that it will use 

 

Dictionary<string, ManagedExtension> extensions

instead of and add comechecking when Extension is adding to dictionary.

List<ManagedExtension> extensions

In dictionary string key is the name of the extension, so there is more space to optimize places where extensions are getting from the dictionary by key. Dictionary is based on HashTable so it could work faster i think. Will see how it will run couple next days. Also did all changes to lists of extension in admin section. Ben if you will be interesting i could send code to you.

Coordinator
Dec 30, 2010 at 6:58 AM

If your code changes prove to eliminate the problem where extensions are listed more than once, then please do either send me your code, or post it here.

Technically, if the app pool recycles, that should clear out all the extensions in memory, and then the next time the site is hit, the extensions should load up ... and there should be just one instance of each extension in memory.

I hope your code changes end up working ... because it would be nice to figure out the problem.  Thanks.