How to disable tomcat created with tomcat7: exec-war

I am using the exec-war target for tomcat7-maven-plugin version 2.1 (not the latest version 2.2 due to MTOMCAT-263 error breaking this target) to create a gang artifact that contains tomcat 7 with my project deployed war. Works great. All this (the server with the war) is started like this:

java -jar foo.jar

      

https://tomcat.apache.org/maven-plugin-2.1/tomcat7-maven-plugin/exec-war-mojo.html

https://tomcat.apache.org/maven-plugin-2.1/executable-war-jar.html

Now I am wondering how to stop working. Who knows?

I need to integrate it into the batch CMD windows script part.

Can I stop it with regular Tomcat? I tried

java -classpath "bin/*" org.apache.catalina.startup.Bootstrap stop

      

but this leads to

java.net.ConnectException: Connection refused: 
connect at java.net.DualStackPlainSocketImpl.connect0(Native Method)

      

+3


source to share





All Articles