You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Ashish Kulkarni <ku...@yahoo.com> on 2002/08/29 18:17:04 UTC

Servlet And Connection pooling and How To

Hi,
I am using Connection pooling and storing the pool in
servlet context and I have question about getting the
connection from servlet context in a all servlets,
I want to code a single class where the input paramter
will be servlet context and session and this class
will return me the connection depending upon some
parameter in session.
I want to keep it is one class so i can change my
implementation in future and change only one class and
my servlets will not be affected
So any suggestions on doing this, one that i think
that this class must have a static method which is
synchronised so i dont have to create instance of this
class in each servlet ,will synchronise slow the
performance, what about using singleton pattern(any
code of singleton pattern)
Any suggestions...

Ashish

__________________________________________________
Do You Yahoo!?
Yahoo! Finance - Get real-time stock quotes
http://finance.yahoo.com

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>