|
|
The servletrunner Utility |
The
servletrunneris in the<jsdk>/bindirectory. You can run the utility more easily if this directory is on your search path. For example:% setenv PATH /usr/local/jsdk/bin: (on UNIX) C> set PATH=C:\jsdk\bin;%PATH% (on Win32)Invoking
servletrunnerwith the-helpflag shows a usage message without running it:
% servletrunner -help Usage: servletrunner [options] Options: -p port the port number to listen on -b backlog the listen backlog -m max maximum number of connection handlers -t timeout connection timeout in milliseconds -d dir servlet directory -r root document root directory -s filename servlet property file name -v verbose output %To see the default values of these options, call
servletrunnerwith the -v option. This starts the utility; just stop it after you have obtained the information if you are not ready to run it yet, or want it to run with something other than the default values. On Unix for example, using thekillcommand stopsservletrunner.% servletrunner -v Server settings: port = 8080 backlog = 50 max handlers = 100 timeout = 5000 servlet dir = ./examples document dir = ./examples servlet propfile = ./examples/servlet.properties
Note: In the default values printed above,servlet dir,document dirand the directory for theservlet propfilecontain a dot ("."). The dot designates the current working directory. The current working directory is typically the directory from which the executable was started. In this case, however, the dot refers to the directory where the servlet development kit is installed.If you start
servletrunnerfrom a directory other than the installation directory,servletrunnerfirst changes its current working directory (and, therefore, what you might think of as the value of the ".").
Once
servletrunneris executing, you can use it to test your servlets.
|
|
The servletrunner Utility |