I have a small problem and don't know how to solve this. While building some java - web applications i use ANT to do the complete process. But when i have already built my WAR and sent it to my remote tomcat(3.3.1) - server, i don't know how do deploy it as part of my ANT - process. My remote tomcat - server is running inside an ANT-loop, so every time i shutdown tomcat ANT will restart it (and deploy my war). So if i cloud teach tomcat to shutdown, using a simple URLConnection inside my local build.xml i'll be happy (and my manager too ). But how can I shutdown tomcat 3.3.1 remotely using a simple URLConnction ?