tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Maxim Veksler" <maxim.veks...@gmail.com>
Subject Re: Command line parameters inside webapps ?
Date Wed, 02 Apr 2008 15:51:06 GMT
On Wed, Apr 2, 2008 at 6:36 PM, David kerber <dckerber@verizon.net> wrote:
> Yes.  You can use System.getProperty( "myPropertyName", "defaultValue" ) to
> retrieve system parameters set on startup with
> -DmyPropertyName="myPropertyValue"
>
>

Great thank you.

>
>  Maxim Veksler wrote:
>
> > Hello everyone,
> >
> > Can I read from my webapp a command line parameters passed to tomcat
> > when it's loaded ?
> > Something of the "-Dsomeparameter=somevalue", alternatively can I get
> > access to environment variables passed to tomcat on it's
> > initialization from my webapp ?
> >
> > What I'm trying to do is allow simple switch that can be passed to my
> > webapp that would instruct it whether it is running passive or active.
> >
> >
> >
> > I've been googling for this and couldn't find any references to this.
> >
> >
> > Thank you,
> > Maxim.
> >




-- 
Cheers,
Maxim Veksler

"Free as in Freedom" - Do u GNU ?

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


Mime
View raw message