简体   繁体   中英

How to publish a Apache-Axis web service in tomcat 6.0

I have developed a simple Apache-Axis java web service using Eclipse IDE and now it works successfully. I have generated test client also which provide by the IDE automatically. I can see that deployed web service is in the IDE server node when I expand it. (I have already added the tomcat 6.0 server to the Eclipse).

But the problem is that web service is up, only if I open the Eclipse and start the server from the Eclipse server tab. If I exit from the Eclipse, web service will be down. I want to know that how can I publish my web service permanently into the tomcat server and make it always up without opening the Eclipse IDE all the time?

thank you all in advance.

note: I just figure out the prob. when I deploy the war file, it has a different name comparing to actual web service project name in eclipse. I just open up the wsdl and get the actual url from it and type it on the address bar. then its worked !. thank u very much for your help. sorry for any inconvenience...

tomcat log file:

Sep 16, 2010 7:33:46 PM org.apache.catalina.core.AprLifecycleListener 
init
INFO: Loaded APR based Apache Tomcat Native library 1.1.20.
Sep 16, 2010 7:33:46 PM org.apache.catalina.core.AprLifecycleListener init
INFO: APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true].
Sep 16, 2010 7:33:47 PM org.apache.coyote.http11.Http11AprProtocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
Sep 16, 2010 7:33:47 PM org.apache.coyote.ajp.AjpAprProtocol init
INFO: Initializing Coyote AJP/1.3 on ajp-8009
Sep 16, 2010 7:33:47 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1403 ms
Sep 16, 2010 7:33:48 PM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Sep 16, 2010 7:33:48 PM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.26
Sep 16, 2010 7:33:48 PM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor host-manager.xml
Sep 16, 2010 7:33:48 PM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor manager.xml
Sep 16, 2010 7:33:49 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory beerV1
Sep 16, 2010 7:33:49 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory docs
Sep 16, 2010 7:33:49 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory examples
Sep 16, 2010 7:33:50 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory ROOT
Sep 16, 2010 7:33:51 PM org.apache.coyote.http11.Http11AprProtocol start
INFO: Starting Coyote HTTP/1.1 on http-8080
Sep 16, 2010 7:33:51 PM org.apache.coyote.ajp.AjpAprProtocol start
INFO: Starting Coyote AJP/1.3 on ajp-8009
Sep 16, 2010 7:33:51 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 3259 ms
Sep 16, 2010 7:34:05 PM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive Server.war
Sep 16, 2010 7:34:06 PM org.apache.axis.utils.JavaUtils isAttachmentSupported
WARNING: Unable to find required classes (javax.activation.DataHandler and javax.mail.internet.MimeMultipart). Attachment support is disabled.

Currently you are using Tomcat from Eclipse which will ofcourse shutdown as you close the eclipse.

Copy your war file in your tomcat/webapps/

and start tomcat /tomcat/bin/tomcat.exe [or .sh ]without depending on the eclipse

  • Stop Tomcat.

  • Delete existing deployment. If you have previously deployed "foo.war" in TOMCAT_HOME/webapps, then it has been unpacked into webapps/foo/... You must delete this directory and all its contents. On Unix, this can be done with rm -r $TOMCAT_HOME/webapps/foo

  • Copy WAR file to TOMCAT_HOME/webapps/.

  • Start Tomcat.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM