Enable your code and application server for debugging
For debugging purposes, it is recommended that you create a separate application server instance and deploy your enterprise application into it. For information on how to create an instance, see the Create a new instance topic in Administration. This way you do not impact the execution of other applications.
Perform these steps to enable your enterprise application and application server for debugging:
- Compile the Java source code specifying the -g option, as shown in this example:
javac -g MyServlet.javaUpdate your enterprise application with the debug-enabled class files, and deploy the application in an application server.
- Disable the just-in-time (JIT) compiler for the application server running the code you want to debug. To disable the JIT compiler from the administrative console, follow these steps:
- Start the administrative console.
- Expand Servers and click the Application Serverslink.
- Click the link for the application server running the code you wish to debug.
- Select the Configuration tab.
- Scroll down to the Additional Properties section and click the Process Definition link.
- In the Additional Properties section, click the Java Virtual Machine link.
- Check the Disable JIT checkbox.
- Click the OK button.
- Click the Save near the top of the page. On the resulting page, click the Save button.
If the application server is running, stop it.
Start the application server.
- Determine the job number, user and name of the iSeries job which represents your application server started in step 4.
The job information can be determined through an iSeries session. See Determine the iSeries job to debug for details on how to determine the iSeries job to debug from an iSeries session.