NonStop Servlets for JavaServer Pages (NSJSP) 6.1 System Administrator's Guide

Debugging NSJSP
NonStop Servlets for JavaServer Pages (NSJSP) 6.1 System Administrator’s Guide
596210-006
6-3
Debugging using Eclipse platform
Add the following arguments in the Arglist of servlet.config file:
-Xdebug -Xnoagent -Djava.compiler=none
-Xrunjdwp:server=y,transport=dt_socket,suspend=n
Set the Numstatic and Maxservers values to greater than or equal to 1
During NSJSP startup, when the port number is not specified in the
servlet.config file, the debug ports are dynamically allocated to
individual NSJSP processes. These allocated ports are captured in
<Servlet Server Class name>.out file present in
<NSJSP_HOME>/logs directory.
For example:
For Numstatic equal to 4, the ports allocated is displayed in the
<Servlet Server Class name>.out file as shown:
Listening for transport dt_socket at address:4129
Listening for transport dt_socket at address:4131
Listening for transport dt_socket at address:4130
Listening for transport dt_socket at address:4133
These debug ports, can now be connected from Eclipse.
When Numstatic is greater than 1, the ports used for debugging are
generated dynamically and therefore cannot be customized in the
servlet.config file.
c. Debugging web application with Numstatic greater than 1 with debug port
range
If you intend to debug a specific port range with Numstatic and Maxservers
value greater than 1, make the following changes to the servlet.config
file in <NSJSP_HOME>/conf directory:
Add the following arguments in the Arglist of servlet.config
file:
Arglist -Xdebug -Xnoagent -Djava.compiler=none -
Xrunjdwp:server=y,transport=dt_socket,suspend=n,addr
ess=<min-debug-port> - <max-debug-port>
Set the Numstatic and Maxservers value to 1
This option is supported in the NonStop Server for Java T2766H60^ACA
SPR onwards.
2. Launch Eclipse and select Debug Configuration window. Connect to the NSJSP
process using the port as mentioned in <Servlet Server Class name>.out
file.
3. The debug configurations can be created for individual NSJSP process. However,
if you intend to debug for specific NSJSP processes, say process $Y1BX, to
identify the debug port associated with the process to be used for Eclipse
connection, complete the following steps: