Volker Schmitt wrote:
Hm, If I look to the ECM code (ResourceLimitingPool):The last days showed that we have a lot of potential memory leaks, see
[1] http://marc.theaimsgroup.com/?t=107330680600002&r=1&w=2 and
[2] http://marc.theaimsgroup.com/?t=107355695400003&r=1&w=2
This is caused by the simple fact that in some cases the recycle()
method of a Recyclable component is not called (see [2] for some
details about that).
/** * Returns a poolable to the pool and notifies any thread blocking. * * @param poolable Poolable to return to the pool. */ public void put( Poolable poolable ) { // Handle Recyclable objects if( poolable instanceof Recyclable ) { ( (Recyclable)poolable ).recycle(); } synchronized( m_semaphore ) {
it can' t be the case (for ECM) that a component is not recycled, because
calling recycle is done before checking the pool full condition. I agree,
that this is not a defined behavior and can be container dependent.
Can some of you guys point to the link where this behavior (not calling recycle()) is defined?
Vadim
