This server can be specially useful in debugging, because it allows debugging Jaxcent with any Java IDE.
To use this server, the files jaxcentFramework21.jar
and jaxcent21.jar
need to be in the classpath.
To start the server from the command line, the syntax is:
java jaxcentServer.ServerMain <port-number> <HTML-root> <XML-Config-file> <Optional-Reloadable-classpath>For instance,
java jaxcentServer.ServerMain 80 C:\MyHtmlFiles C:\JaxcentConfig.xmlor
java jaxcentServer.ServerMain 80 C:\MyHtmlFiles C:\JaxcentConfig.xml C:\MyJaxcentClassesWhen debugging, the reloadable classpath should not be used as it could confuse the debugger -- instead the necessary classpath should be provided to the IDE.
jaxcentServer.ServerMain
. This class extends java.lang.Thread
. After
instantiating it, start the thread. E.g.
ServerMain jaxcentServer = new ServerMain( 80, htmlDir, xmlConfigFile, reloadableClasspath ); jaxcentServer.start();The last parameter
reloadableClasspath
can be null
. In debugging,
typically you may want to provide null
here, and specify the full classpath in the IDE.