Tutorial:Remote Execution for Debugging

From OpenTutorials
Jump to: navigation, search

With remote debugging, one can debug Cytoscape apps (or Cytoscape itself) within Eclipse.

Start Cytoscape in Debug Mode

To start Cytoscape in debug mode, run Cytoscape with debug as the first command line argument:

In Windows

cytoscape.bat debug

In Linux/Mac

./cytoscape.sh debug


Make sure you can see the following message in the terminal:

Listening for transport dt_socket at address: 12345

Run Debugger From Eclipse

  • Click Run and select Debug Configurations...
  • Select Remote Java Applications and create new configuration
  • Select/Enter the following and press Apply:
    • Name: Cytoscape3
    • Project: myproject (your project name may be different; so "browse" to find the one you are about to debug )
    • Connection Type: Standard (Socket Attach)
    • Host: localhost
    • Port: 12345 (or the port specified in the cytoscape.sh file)
  • Press Debug. This starts up Cytoscape 3. After 20-30 seconds, you will see the Cytoscape desktop.
  • Set a breakpoint in Eclipse
  • Switch Perspective to Debug mode: Window → Perspective → Debug
  • Load the bundle into your OSGi container and run