Server User Manual

Table Of Contents
Chapter 7: Using JBuilder with BEA WebLogic servers 71
Remote debugging
A few WebLogic Server properties, such as field groups and other CMP WebLogic-
specific properties, were previously accessed only through the EJB Designer. You can
now access them through the EJB DD Editor as well.
Remote debugging
To prepare to debug remotely, launch the WebLogic Server with debug parameters. To
do this, modify
startWebLogic.sh in your domain directory and add the following
parameters to the JAVA_OPTIONS variable:
-Xdebug
-Djava.compiler=NONE
-Xrunjdwp:transport=dt_socket,server=y,address=3999,suspend=n
Within JBuilder, follow these steps:
1 In the project from which you want to launch the remote debug session, click Run|
Configurations. If you have not yet created a server type run configuration, click
New and select type Server. If you have already created a server type run
configuration, select it and choose Edit.
2 Select Debug|Remote in the tree.
3 Check the Enable Remote Debugging option.
4 Enter the host name (the name of the machine on which the server is running.)
5 Click OK.
6 Click the down arrow next to the Debug Project icon ( ) on the JBuilder toolbar
and select the debug run configuration you just created or edited. You will now be
able to set breakpoints in Java code, such as in EJBs, servlets, and so on.
Remote debugging of JavaServer Pages
To debug JSPs remotely, open the project containing the web application you want to
debug and follow these steps,
1 Expand the web application node in the project and expand the deployment
descriptors node under the web application node.
2 Double-click weblogic.xml and add the following descriptor elements:
<jsp-descriptor>
<jsp-param>
<param-name>keepgenerated</param-name>
<param-value>true</param-value>
</jsp-param>
<jsp-param>
<param-name>debug</param-name>
<param-value>true</param-value>
</jsp-param>
<jsp-param>
<param-name>precompile</param-name>
<param-value>true</param-value>
</jsp-param>
<jsp-param>
<param-name>compileFlags</param-name>
<param-value>-g</param-value>
</jsp-param>
</jsp-descriptor>
3 Rebuild project and deploy the web application (as a WAR).