You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by Donie Kelly <do...@tecnomen.ie> on 2003/03/19 12:02:47 UTC

Newbie question on pools

 
Hi all
 
I've looked through the source and all the javadocs and I cannot find a way
to do the following with the pool library. Note I have marked that I can
achieve parts of the intended functions:
 
1)      Get a connection from the pool (I can do this)
2)      Use the connection (I can do this)
3)      Return the connection to the pool (I can do this)
4)      When I get a connection and I have detected it has failed how can I
mark it for removal as it may have been dropped by the server at the other
end of the connection (HOW TO??)
 
 
I understand that I can use the pool ObjectPoolFactory to test connections
on retrieval and submission to the pool but this is an overhead I don't
want. I want the pool to drop the connection when the application has
decided it is bad. I know the other way is desirable and I will probably
implement this by using the evictor thread but surely it's important for the
application to be able to decide that the connection is useless??
 
The connection I'm pooling is a Corba connection object.
Thanks for any insights or help.
 
Donie