You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Remy Maucherat <re...@apache.org> on 2003/07/07 23:54:32 UTC

[5.0] Removing session recycling code

Hi,

I'd like to completely remove session recycling code from TC 5, as it is 
a potentially dangerous feature (which has been disabled in TC 4.1.x) 
and does not bring any actual performance improvement while using memory.
The biggest impact of the change is the removal of the recycled array 
list for base manager, which can break existing TC 4 managers. OTOH, 
using that is unsafe, and fixing an affected manager is very easy (just 
remove whatever recylcling code was used).

I plan to keep Session.recycle around (nulling out references can help 
GC, esp since there could be a lot of session objects - with all their 
children - waiting to be GCed).

Comments ?

Remy



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


Re: [5.0] Removing session recycling code

Posted by Bill Barker <wb...@wilshire.com>.
----- Original Message -----
From: "Remy Maucherat" <re...@apache.org>
To: "Tomcat Developers List" <to...@jakarta.apache.org>
Sent: Monday, July 07, 2003 2:54 PM
Subject: [5.0] Removing session recycling code


> Hi,
>
> I'd like to completely remove session recycling code from TC 5, as it is
> a potentially dangerous feature (which has been disabled in TC 4.1.x)
> and does not bring any actual performance improvement while using memory.
> The biggest impact of the change is the removal of the recycled array
> list for base manager, which can break existing TC 4 managers. OTOH,
> using that is unsafe, and fixing an affected manager is very easy (just
> remove whatever recylcling code was used).
>
> I plan to keep Session.recycle around (nulling out references can help
> GC, esp since there could be a lot of session objects - with all their
> children - waiting to be GCed).
>
> Comments ?

Having put so much work into getting the session recycling code working in
3.3, I'm +1 for not seeing that headache again ;-).


>
> Remy
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org
>


Re: [5.0] Removing session recycling code

Posted by Costin Manolache <cm...@yahoo.com>.
+1 

The session is a long-lived object, so the improvement on recycling is
minor. 

Costin

Remy Maucherat wrote:

> Hi,
> 
> I'd like to completely remove session recycling code from TC 5, as it is
> a potentially dangerous feature (which has been disabled in TC 4.1.x)
> and does not bring any actual performance improvement while using memory.
> The biggest impact of the change is the removal of the recycled array
> list for base manager, which can break existing TC 4 managers. OTOH,
> using that is unsafe, and fixing an affected manager is very easy (just
> remove whatever recylcling code was used).
> 
> I plan to keep Session.recycle around (nulling out references can help
> GC, esp since there could be a lot of session objects - with all their
> children - waiting to be GCed).
> 
> Comments ?
> 
> Remy



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


Re: [5.0] Removing session recycling code

Posted by Glenn Nielsen <gl...@mail.more.net>.
I agree that session recycling can be a security problem but am concerned
that removing recycling will significantly increase GC overhead.  I would
like to see some before and after GC data from testing where 1000's of sessions
get used per hour.  Testing with different versions of the JVM would be needed
since GC performance varies a great deal between JVM's.

Regards,

Glenn


Remy Maucherat wrote:
> Hi,
> 
> I'd like to completely remove session recycling code from TC 5, as it is 
> a potentially dangerous feature (which has been disabled in TC 4.1.x) 
> and does not bring any actual performance improvement while using memory.
> The biggest impact of the change is the removal of the recycled array 
> list for base manager, which can break existing TC 4 managers. OTOH, 
> using that is unsafe, and fixing an affected manager is very easy (just 
> remove whatever recylcling code was used).
> 
> I plan to keep Session.recycle around (nulling out references can help 
> GC, esp since there could be a lot of session objects - with all their 
> children - waiting to be GCed).
> 
> Comments ?
> 
> Remy
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org
> 



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


Re: [5.0] Removing session recycling code

Posted by kev <ke...@neoapathy.org>.
> I'd like to completely remove session recycling code from TC 5, as it 
> is a potentially dangerous feature (which has been disabled in TC 
> 4.1.x) and does not bring any actual performance improvement while 
> using memory.
> The biggest impact of the change is the removal of the recycled array 
> list for base manager, which can break existing TC 4 managers. OTOH, 
> using that is unsafe, and fixing an affected manager is very easy 
> (just remove whatever recylcling code was used).
>
> I plan to keep Session.recycle around (nulling out references can help 
> GC, esp since there could be a lot of session objects - with all their 
> children - waiting to be GCed).
>
> Comments ?

If it can't be used safely at all my gut instinct would be to remove it 
to prevent something from blowing up in peoples faces.  It also sounds 
like a "performance enhancement" which has gone wrong, so it's a prime 
candidate for removal in my opinion. (But then what do I know :)

erm +1 is it?

Kev

--
"To be governed is to be watched over, inspected, spied on, directed, 
legislated..." - Pierre-Joseph Proudhon


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