Using the BPEL Designer and Service Engine

Using Breakpoints to Debug BPEL Processes

Breakpoints are used to instruct the BPEL Debugger to stop execution at the specified place of a BPEL process. When a BPEL process instance reaches a breakpoint, it becomes suspended and you can step into the code, change the current process instance in the BPEL Process Instances window, track the execution of the process instance in the BPEL Process Execution window and in the Design view, examine the values of variables in the Local Variables window, view the process partner links in the Partner Links window and view the values of XPath expressions in the Watches window.

You can also use fault breakpoints to check the values of variables before a fault is thrown.

To view and organize the breakpoints currently set in the IDE, open the Breakpoints window by choosing Windows -> Debugging -> Breakpoints (Alt-Shift-5). For each breakpoint, you can see the name of the file and the line where this breakpoint is located. In the Breakpoints window you can enable and disable breakpoints by checking or removing the checkbox in the Enabled column.

ProcedureTo set a breakpoint in a BPEL process

  1. In the IDE, open the BPEL file in either the Source or Design view.

  2. Do one of the following:

    • In the Source view, click the left margin of the row where you want to place a breakpoint.

    • In the Design view, right-click an element where you want to place a breakpoint and choose Toggle Breakpoint (Ctrl-F8).

      In the Design view, breakpoints are displayed as small red squares on top of specific elements. In the Source view, breakpoints are shown as red squares on the left margins of code lines.

      Alternatively, you can set and remove breakpoints in the BPEL Logical view of the Navigator window by choosing Toggle Breakpoint from the pop-up menu. In the Navigator window breakpoints are shown as small red squares attached to elements.

      Once the project has reached the breakpoint it is suspended. You can manage the subsequent execution using the commands available in the Run menu or as buttons on the toolbar.

Debugging Commands

The following commands are available from within the debugging session:

ProcedureTo remove a breakpoint from the BPEL process

  1. In the Source view, On the diagram, click the left margin of the line that contains the breakpoint.

  2. In the Breakpoints window, right-click the breakpoint you want to remove and choose Delete. Choosing Delete All from the pop-up menu removes all breakpoints currently set in the NetBeans IDE.

  3. 3. In the Design view, right-click the element that has a red breakpoint mark and choose Toggle Breakpoint.

To disable a breakpoint

To disable a breakpoint do one of the following:

Group operations over breakpoints

The toolbar contains three buttons for group operations over the process breakpoints.