tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <ch...@christopherschultz.net>
Subject Re: [OT] Re: problems at thejarbar.org
Date Fri, 11 Jun 2010 20:59:12 GMT
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Yucca Nel,

On 6/11/2010 4:53 AM, yuccanel@live.co.za wrote:
> Hello tomcats !! :) A quick question as I tackle configuring jndi
> resource for first time: I was referred to using jndi in production
> environmrnt snd hsve noted through documentation found in  test server
> that there are 3 possible places to define jndi resources:
> 1)the server .xml(for every webapp in server if I am correct.

Yes, you can define site-wide JNDI resources, here, but I'd recommend
against it.

> 2)context.xml

I think this is the best place to put JNDI resource definitions.

> 3)web.xml

You can't actually define JNDI resources, here: only map global
(server.xml) ones to the webapp.

> As I am planning on only using this resource for multiple webapps in
> same domain, am I right in asuming server.xml is correct choice to
> define jndi resource?

Perhaps. if you want to share database pools, then do it at the
server.xml level. If you want each webapp to have it's own pool, you
might consider separating them (even if the details are the same).

> In addition I am to define jndi used in server.xml again in web.xml?

My experience is that you do not need to map them in web.xml, though the
servlet spec seems to indicate that doing so is appropriate.

> I now need to know how / where to configure parameters for mysql
> connections or are the defaults acceptable for production?

You can find connection pool settings here:

http://commons.apache.org/dbcp/configuration.html

You can find documentation for configuring Connector/J in the MySQL
documentation that matches your version number.

Good luck,
- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkwSo6AACgkQ9CaO5/Lv0PDuvQCcCgg07IDlP/LvRAUGq2UsIlIp
zrkAoJHGUDedkqybZdcTuSNSnyLw22yC
=8Ghi
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message