Hi Yoav,

It looks like setting a context parameter is the cleanest way to do it.
Setting properties through the startup files or registry makes it a bit
more cumbersome to install the app.

Thanks for your help,

Brent.


-----Original Message-----
From: Shapira, Yoav [mailto:[EMAIL PROTECTED] 
Sent: Thursday, 18 September 2003 10:43 PM
To: Tomcat Users List
Subject: RE: Setting JVM properties via Tomcat config



Howdy,
Your could put the property as a context-param in your web.xml, then in
a ServletContextListener's contextInitialied method get the context
param value and use System.setProperty to set the system property your
3rd party library needs.

That said, I wouldn't do the above, but instead use JAVA_OPTS for
tomcat.  It's cleaner IMHO, but this is a personal style matter.

Yoav Shapira
Millennium ChemInformatics


>-----Original Message-----
>From: Brent Snook [mailto:[EMAIL PROTECTED]
>Sent: Wednesday, September 17, 2003 7:35 PM
>To: [EMAIL PROTECTED]
>Subject: Setting JVM properties via Tomcat config
>
>Hi,
>
>I have a web app. using a third party library that requires that a 
>property be set in the JVM.
>
>I am aware of how to set the property using the catalina start-up 
>scripts and via Win2000 registry keys but my supervisor would like to 
>know if it can be set using the Tomcat configuration files or the web 
>descriptor for the app. This would make installation is a bit easier
and
>we'd like to avoid changing any code.
>
>Any suggestions would be appreciated.
>
>Thanks,
>
>Brent.
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to