For tomcat you can define JAVA_OPTS system variable to supply
additional parameters for the java machine. That includes the
possibility to define -Dyour.property=
See the comments at the begin of catalina.bat or catalina.sh.
You can either modify catalina.bat/.sh or whatever bat file that is
used
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Martin,
Martin Gainty wrote:
> did you try setting the init-param in web.xml e.g.
>
>
> my.property
> 1
>
This is entirely unhelpful and has nothing to do with system properties. :(
- -chris
-BEGIN PGP
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Kaj,
Kaj Kandler wrote:
> Trickily I can't change the library (forgot to mention that), so I have
> to depend on the property value and can't change it to a JNDI lookup.
>
> Well, I did the following:
> As I use Spring anyway, I created a bean proper
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Thanks Christopher,
I appreciate the quick response.
Trickily I can't change the library (forgot to mention that), so I have
to depend on the property value and can't change it to a JNDI lookup.
Well, I did the following:
As I use Spring anyway, I cr
did you try setting the init-param in web.xml e.g.
my.property
1
M--
- Original Message -
From: "Kaj Kandler" <[EMAIL PROTECTED]>
To: "Tomcat Users List"
Sent: Wednesday, November 14, 2007 1:07 PM
Subject: Setting Java property inside a webapp
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Kaj,
Kaj Kandler wrote:
> Hi there,
> I do have a library, that uses a property to determine some
> configuration. As a straight Java program I would call
>
> java -dmy.property=/my/value ...
>
> How can I set this property in the context of a tomca