Debugging NetPhantom Server Applications

The application under development can be launched for testing purposes. This will create a temporary in-memory distribution to run on the internal NetPhantom Server. Even applications containing errors can be launched. Answer Yes in the warning message box and the application will be launched in a “best effort” mode.

Note: When running the Client from Eclipse, project switching is enabled. A new feature in NetPhantom 6 is also that there is no limit as to how many simultaneous client sessions started (NetPhantom 5.5 only allowed one client).

To run the Server application in debug mode means that the Java code written can be debugged in the Eclipse debugger. Also the REXX code can be debugged since the intermediate Java code is saved in the gensrc/rexx directory. In the Java code in that directory, breakpoints can be set.

Warning: When setting breakpoints in the code great care should be taken. Any breakpoint will halt the thread it is running in; do not forget to release it back to running state. That means that the functionalty of Server could be impaired.

As a convenience function, the NetPhantom Eclipse plugin will generate a default debug configuration for connecting to a running NetPhantom application. This launch configuration is called Attach debug to NetPhantom Server. To view this configuration, select the menu item Run – Debug Configurations in Eclipse.