What communication is going on between Eclipse and my application server (JBoss) when I run the server from within Eclipse in debugging mode? How does this work?
Enabling remote debuggingSelect Run → Debug Configurations…. The Debug Configurations dialog box is displayed. Select Remote Java Applications. Select New launch configuration as illustrated in Remote Java application's debug configuration.
A Java program can be debugged simply by right clicking on the Java editor class file from Package explorer. Select Debug As → Java Application or use the shortcut Alt + Shift + D, J instead. Either actions mentioned above creates a new Debug Launch Configuration and uses it to start the Java application.
4) In Eclipse, from the Run menu, click Debug and create a new 'Remote Java Application'. 5) Select your project, enter 9091 for the connection port number and click Debug. Eclipse should now switch you to the Debug perspective which shows you running threads, breakpoints, variables and your source code.
When you start the server in debug mode, it listens on a specified TCP port. Eclipse connects to that port, and they talk using the Java Debug Wire Protocol (JDWP). Read the details here: http://java.sun.com/j2se/1.5.0/docs/guide/jpda/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With