You could have the servlet write a file that is then checked for by an
external application. If the file exists then the external app could kill
the tomcat. 


Rob

-----Original Message-----
From: afolli [mailto:[EMAIL PROTECTED] 
Sent: 25 July 2008 09:20
To: users@tomcat.apache.org
Subject: Stop tomcat on Startup



Hi All. I want to perform some checks on tomcat startup. If there is an
error, I want to stop tomcat. I have defined a servlet and defined it as
follow in the web.xml file in order to load it.

        <servlet>
                <description>
                </description>
                <display-name>
                StartUp</display-name>
                <servlet-name>StartUp</servlet-name>
                <servlet-class>
                com.webservice.global.StartUp</servlet-class>
                <load-on-startup>200</load-on-startup>
        </servlet>

        <servlet-mapping>
                <servlet-name>StartUp</servlet-name>
                <url-pattern>/StartUp</url-pattern>
        </servlet-mapping>

How can I stop the upcoming tomcat from the servlet?

Thanks,

  Alessandro
--
View this message in context:
http://www.nabble.com/Stop-tomcat-on-Startup-tp18647289p18647289.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


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



***********************************************************************
This  message  may  contain  confidential and  privileged  information.
If you  are not the  intended recipient  you should not  disclose, copy
or distribute information in this e-mail or take any action in reliance
on its contents.  To do so is strictly  prohibited and may be unlawful.
Please  inform  the  sender that  this  message has  gone astray before
deleting it.  Thank you.

2008 marks the 60th anniversary of the NHS.  It's an opportunity to pay
tribute to the NHS staff and volunteers who help shape the service, and
celebrate their achievements.

If you work for the NHS  and  would like  an NHSmail  email account, go
to: www.connectingforhealth.nhs.uk/nhsmail
***********************************************************************


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

Reply via email to