Evan,

What you are doing does not seem necessary depending on the server that you
are using.
Keep in mind that ejbs are of a transactional nature and do not really need
to use them to initialize a pool.  I am using the Weblogic server and it
comes with a pooling feature and I believe most servers do.

Some where in your servers configuration properties should be a setting to
create a pool. This is will be initialized upons startup.  Do create your
own solutions.  You can then use something like :

      Properties props = sessionContext.getEnvironment();
      String url = props.getProperty("url");
      return DriverManager.getConnection(url);

to get a connection.

Hope this helps.
Suneet Shah
Architect - Diamelle Technologies
http://www.diamelletechnologies.com
visit us at Pod 1019

-----Original Message-----
From: Evan Vaala <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED] <[EMAIL PROTECTED]>
Date: Thursday, December 02, 1999 10:51 PM
Subject: Bean-Managed Persistance - Initializing db connection pool


>Does this scenario sound ok?
>
>I want to create an ejb that will provide the initialization and admin
routines
>on a static db connection pool.
>
>This ejb will have an initialization routine that will create the db
connection
>pool and place it into the InitialContext.
>
>Following startup of the ejb server, an admin routine would be run that
would
>create/initialize this ejb that would then create the db connection pool
making
>it available for other beans to access.
>
>Does this sound ok?
>
>If there is a standard to adhere to for initializing db connections, I
would be
>interested in a URL that describes it.  I am aware of the jdbc objects for
>"pooling" but what I want to know is the best way to initialize these in an
ejb
>server.
>
>Thanks!
>
>Evan Vaala
>
>===========================================================================
>To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
>FAQs on JSP can be found at:
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html

Reply via email to