GoLand 2019.2 Help

Multiprocess debugging

With GoLand, you can debug additional Node.js processes that are launched by the child_process.fork() method or by the cluster module. Such processes are shown as threads in the Frame pane on the Debugger tab of the Debug Tool Window.

  1. Set the breakpoints in the processes to debug.

  2. Create a Node.js run/debug configuration.

  3. Select the newly created configuration from the Select run/debug configuration list on the toolbar and click Debug the Debug button.

    The Debug Tool Window opens and the Frames list shows the additional processes as threads as soon as they are launched:

    ws_node_multiprocess.png

    To examine the data (variables, watches, and so on) for a process, select its thread in the list and view its data in the Variables and Watches panes. When you select another process, the contents of the panes are updated accordingly.

Last modified: 29 October 2019