tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Craig R. McClanahan" <>
Subject Re: whatsup with env-entry in web.xml and other property flakiness
Date Wed, 24 May 2000 21:46:00 GMT
Rick Bosch wrote:

> tried to set some values in the env-entry in web.xml, but I cant seem to get
> them out with System.getProperty() and I looked in the petstore demo and
> they use some jndi thing that seems like overkill for what I need.
> I also cant set variable in the tomcat .properties with
> wrapper.env=[name]=[value] , htis was always flaky in jserv.  Has anybody
> got this working .
> I cant even get wrapper.bin.parameters=-Drick=izmyname  to work.
> Basically is anyone able to pass runtime properties to your program and how
> are you doing it,  or have you got any of the above working?

The <env-entry> stuff is there for J2EE-integrated servlet containers
Tomcat by itself is not).  These entries would be accessible through
JNDI, as
described in the J2EE specification.

What you might be looking for is context initialization parameters:


which can be accessed from any servlet or JSP page in your application,

    String value = (String)

in a manner analogous to the way that servlet initialization parameters
let you
configure an individual servlet.

> thanks();
> rick

Craig McClanahan

View raw message