tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shapira, Yoav" <>
Subject RE: Binding DataSources to Contexts in Tomcat 4.06/4.1
Date Thu, 19 Aug 2004 18:29:09 GMT


>In both servers the Resource declarations are in the <DefaultContext>
>block.  All DataSources are shared by all webapps.

You realize that by placing a Resource in DefaultContext you ensure that
a separate copy is created for each Context, right?  That means if you
configure for 10 max connections and have 5 Contexts, you will have 5
DataSources with 50 total max connections possible.  Unless this is
really what you want, consider having the DataSource defined in the
actual Context element instead of DefaultContext.

>I do not have a
>resource-ref declaration in either web.xml ... I'll go look that up and

OK -- it's required.

What is the purpose of the factory parameter, and what is an
>appropriate value?

To specify a factory for pooling connections.  The default value for
DBCP is <parameter>

This is documented on the JNDI DataSources How-To page.  I suggest you
read it if you haven't already:

Yoav Shapira

This e-mail, including any attachments, is a confidential business communication, and may
contain information that is confidential, proprietary and/or privileged.  This e-mail is intended
only for the individual(s) to whom it is addressed, and may not be saved, copied, printed,
disclosed or used by anyone else.  If you are not the(an) intended recipient, please immediately
delete this e-mail from your computer system and notify the sender.  Thank you.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message