Debugging: stepping through source code

When message flow processing is paused at a breakpoint on entry to a node that contains ESQL code or Java™ code, you can step through the code.

Before you begin

Add one or more breakpoints to your message flow; see Adding breakpoints in the flow debugger.

About this task

The nodes that can contain ESQL code or Java code are listed in Flow debugger overview.

To step through your source code, complete the following steps.

Procedure

  1. Switch to the Debug perspective.
  2. In the Debug view, click Step into Source Code Step into code on the toolbar.

    Alternatively, right-click the flow stack frame, then click Step Into Step Into.

  3. When message flow processing is paused at a breakpoint in the ESQL or Java code, you can step through the source code line by line. In the Debug view, click Step Over Step Over on the toolbar.

    Alternatively, right-click the flow stack frame, then click Step Over Step Over.

    Repeat this step as often as necessary.

    A single line of source code runs and the flow pauses at the next line of code. What you can do depends on what type of code is contained within the node. For more information, see on of the following topics:

    If the debugger is paused before the last line of code when you step over, the last line of code runs and message flow processing continues until the next breakpoint in the logical processing of the current message. If no further enabled breakpoint exists at which the flow instance can pause, processing runs to completion and the flow instance is removed from the Debug view.

  4. If you finish looking at the code before the last breakpoint, you can continue processing the message flow. In the Debug view, click Step Return Step Return on the toolbar.

    Alternatively, right-click the flow stack frame, then click Step Return Step Return.

    The source code runs to completion from the current breakpoint and message flow processing continues until the next breakpoint that is set in the logical processing of the current message. If no further enabled breakpoint exists at which the flow instance can pause, processing runs to completion and the flow instance is removed from the Debug view.

What to do next

If message flow debugging is complete, you can remove the breakpoints or end the debugging session: