How remote debugging an java application server using eclipse
Startjava application and tell the JVM that it will be debugged remotely
For this, add the following options to the
JVM arguments for remote debugging:
java -Xdebug -Xrunjdwp:transport=dt_socket,address=8998,server=y,suspend=n
And then just start
IDE's remote debugger to listening on port 8998
transport=dt_socket tells that the
debugger connections will be made through a socket while the address=8998 parameter informs it that the port number will be 8998. For suspend=y , the JVM starts in suspended mode and stays suspended until a debugger is attached to it.
Configuring Eclipse to Debug a Remotely Running Application
- Start Eclipse
- Navigate to Run -> Debug Configurations
- Create a new Remote Java Application configuration
- Configure the remote application's details
- click Apply
JPDA
Debugging J2EE Applications
Debugging with the Eclipse Platform