Showing posts with label Remote Debugging in tomcat. Show all posts
Showing posts with label Remote Debugging in tomcat. Show all posts

Monday, 13 October 2014

Setting Up Tomcat For Remote Debugging Windows

Debugging a J2EE application is one of the most basic needs of a developer. We can debug a standalone application easily by adding one breakpoint and running the debugger.However debugging a remotely hosted application needs to have a certain application server specific settings

For this you need to configure JPDA (Java Platform Debugger Architecture) in your tomcat.

Add the following two lines in the first line of tomcat's "startup.bat"


set JPDA_ADDRESS=8000
set JPDA_TRANSPORT=dt_socket

Your startup.bat may now be like - 

set JPDA_ADDRESS=8000
set JPDA_TRANSPORT=dt_socket
if "%OS%" == "Windows_NT" setlocal
and so on 

Replace the line 
call "%EXECUTABLE%" start %CMD_LINE_ARGS%

with 

call "%EXECUTABLE%" jpda start %CMD_LINE_ARGS%

Restart the server. 
Your tomcat is setup for remote debugging.