ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William BC Crandall" <bc.crand...@earthlink.net>
Subject Re: Tomcat startup/shutdown
Date Sat, 12 Jun 2004 23:11:39 GMT
Hello Ivan,

Thanks very much for your macrodef, it does the trick.

I only had to add a property definition pointing to my
catalina.home, and then it worked fine. 

Am I right that the lines: 

>             <sysproperty key="catalina.home"
>                  value="${catalina.home}"/>

are passing my local catalina home to the property
of the same name in bootstrap.jar? (Just trying to
understand what's going on.)

Thanks again, and best wishes,


William BC Crandall
bc.crandall [around] earthlink.net






----- Original Message ----- 
From: "Ivan Ivanov" <rambiusparkisanius@yahoo.com>
To: "Ant Users List" <user@ant.apache.org>
Sent: 10 June 2004 11:53 PM
Subject: Re: Tomcat startup/shutdown


> Hello Willian,
> 
> I wrote a macrodef for a quick way to start/stop
> tomcat. Here it is:
> 
> <macrodef name="tomcat.utils" description="Macrodef
> for starting/stopping Tomcat">
>     <!-- the action passed to tomcat bootstrap process
> -->
>     <attribute name="action"/>
>     <sequential>
>         <java
> classname="org.apache.catalina.startup.Bootstrap"
> fork="yes" failonerror="yes">
>             <classpath>
>                 <pathelement
> location="${catalina.home}/bin/bootstrap.jar"/>
>             </classpath>
>             <arg value="@{action}"/>
>             <sysproperty key="catalina.home"
> value="${catalina.home}"/>
>         </java>
>     </sequential>
> </macrodef>
> 
> Then I invoked this macrodef in a target in this way
> <tomcat.utils action="start"/> <!-- Start tomcat -->
> <tomcat.utils action="stop"/> <!-- Start tomcat -->
> 
> HTH Ivan
> 
> --- William BC Crandall <bc.crandall@earthlink.net>
> wrote:
> > 
> > Greetings, fellow Antophiles,
> > 
> > Eric Burke and Brian Coyner state that "As of [March
> > 2003]
> > there is no generic way to [start and stop Tomcat
> > from Ant]."
> > 
> > They then offer some classes to do just that. (In
> > _Java
> > Extreme Programming Cookbook_, p. 245, with code
> > samples
> > available at
> > http://examples.oreilly.com/jextprockbk/
> > 
> > In the last year and a half, has anyone devised an
> > Ant task
> > for this? Or is their code the best place to start? 
> > 
> > Thanks to all for any pointers.
> > 
> > Best wishes,
> > 
> > William BC Crandall
> > bc.crandall [around] earthlink.net
> > 
> > 
> > 
> > 
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> > user-unsubscribe@ant.apache.org
> > For additional commands, e-mail:
> > user-help@ant.apache.org
> > 
> 
> 
> 
> 
> 
> __________________________________
> Do you Yahoo!?
> Friends.  Fun.  Try the all-new Yahoo! Messenger.
> http://messenger.yahoo.com/ 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message