| |
|
| java.lang.Object java.lang.Thread org.apache.cactus.integration.ant.container.AbstractServerRun
All known Subclasses: org.apache.cactus.integration.ant.container.enhydra.EnhydraRun, org.apache.cactus.integration.ant.container.resin.ResinRun,
AbstractServerRun | abstract public class AbstractServerRun extends Thread (Code) | | Abstract class for starting/stopping an application server. When this
application is first called to start the server, a listener socket is
set up. Then, we it is later called to stop the server, we connect to the
listener socket and tell the server to stop.
version: $Id: AbstractServerRun.java 238918 2004-04-18 12:21:50Z vmassol $ |
Method Summary | |
final protected void | doRun() Parse and process the command line to start/stop the server. | abstract protected Thread | doStartServer(String[] theArgs) Starts the server (in a blocking mode) and set up a socket listener. | abstract protected void | doStopServer(String[] theArgs, Thread theRunningServerThread) Stops the server by connecting to the socket set up when the server
was started. | public void | run() Sets up a listener socket and wait until we receive a request on it to
stop the running server. |
AbstractServerRun | public AbstractServerRun(String[] theArgs)(Code) | | Parameters: theArgs - the command line arguments |
doRun | final protected void doRun()(Code) | | Parse and process the command line to start/stop the server.
|
doStartServer | abstract protected Thread doStartServer(String[] theArgs) throws Exception(Code) | | Starts the server (in a blocking mode) and set up a socket listener.
the thread in which the server has been started Parameters: theArgs - the command line arguments exception: Exception - if any error happens when starting the server |
doStopServer | abstract protected void doStopServer(String[] theArgs, Thread theRunningServerThread) throws Exception(Code) | | Stops the server by connecting to the socket set up when the server
was started.
Parameters: theArgs - the command line arguments Parameters: theRunningServerThread - the thread in which the server is running.This is useful for example if there is no simple way to stop theserver and thus you need to simply try to stop the running thread. exception: Exception - if any error happens when stopping the server |
run | public void run()(Code) | | Sets up a listener socket and wait until we receive a request on it to
stop the running server.
|
|
|
|