excalibur-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vadim Gritsenko <va...@reverycodes.com>
Subject Re: One more change to be included into the release...
Date Wed, 24 Aug 2005 02:52:26 GMT
Sasvata (Shash) Chatterjee wrote:
> Vadim,
> 
> Is it really bad enough to hold the release?  Why can we not fix it in 
> the next release?

Well, I can live with private fork for some time...


> PS: Admittedly, my opinion is colored by the grunt-work of making 
> repeated released, but, still...:-)

Hence I colored this as a simple addition not requiring RC4 :-)

Vadim


> Vadim Gritsenko wrote:
> 
>> ... or ThreadLocals are EVIL! If you have not heard the word yet, 
>> ThreadLocals
>> tend to prevent (web) application(s) from being garbage collected when 
>> thread
>> locals are not properly nulled out.
>>
>> So in order to allow web applications using LogKit to be properly 
>> unloaded,
>> LogKit's ContextMap has to have one more method:
>>
>>     /**
>>      * Remove current ContextMap.
>>      * This method removes a ContextMap associated with current thread,
>>      * if there is any.
>>      */
>>     public static void removeCurrentContext()
>>     {
>>         c_localContext.set(null);
>>     }
>>
>>
>> Consistent usage of this method, like:
>>
>> try {
>>     ... ContextMap.getCurrentContext() ...
>> } finally {
>>     ContextMap.removeCurrentContext();
>> }
>>
>> will guarantee that ThreadLocal is properly cleaned up and web app 
>> will be
>> properly unloaded. I'd like to include this addition into the release; 
>> and IMHO
>> there is no reason to do yet another RC build just because of it :-) 
>> because it
>> is simple addition which does not alter any existing behavior.
>>
>> WDYT?
>>
>> Vadim
>>
>> PS http://www.jroller.com/page/tackline?entry=fixing_threadlocal

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@excalibur.apache.org
For additional commands, e-mail: dev-help@excalibur.apache.org


Mime
View raw message