Testing and Debugging Projects : Setting Breakpoints and Running Debugger

Setting Breakpoints and Running Debugger
After you have done the setup (see Preparing to Run (Test) or Debug a Project), add breakpoints in your code and run the debugger as explained below.
To Add Breakpoints in the Rule and Rule Function Code
Setting breakpoints is an Eclipse feature. This section provides only basic information. You can also use advanced features such as importing and exporting breakpoints, and using class prepare breakpoints. See Eclipse help for more details on all breakpoint functionality. You can set or change breakpoints during a debug session also.
1.
You can work with breakpoints in the debugger perspective as well as in the TIBCO BusinessEvents Studio development perspective.
2.
To add a breakpoint put your cursor in the left margin (gray area) next to a row where you want to add a breakpoint. Do one of the following:
A breakpoint icon appears in the left margin:
3.
To edit a breakpoint’s properties, select Breakpoint properties. A dialog displays (with mostly runtime options). For example, you can use a class prepare breakpoint (so the running program is suspended when the specified class or interface is first loaded by the Java VM).
A breakpoint may not be set exactly where you place it. This is because TIBCO BusinessEvents ensures that breakpoints fall on an executable statement, and moves any that don’t to the nearest executable statement.
Executing step code line does not match rule editor code line  This situation happens when there is a mismatch between the debug line information stored in the EAR, and the information in the open rule editor. To resolve the problem, recompile the EAR file.
To Run Debugger
1.
As needed, switch to Debug perspective. Select Window > Open Perspective, or click the Open Perspective () button). Then select Other > Debug.
Alternatively, wait till TIBCO BusinessEvents prompts you to change to debug perspective. This happens when the debugger reaches the first breakpoint.
2.
Launch a configuration: Click the down-arrow to the right of the debugger () button. You see a drop-down list. Do one of the following:
Select a debug configuration from the list. (To add configurations to this list, select Organize Favorites from the debugger drop-down list.)
Click the debugger () button or Select Run > Debug. (Only if you have already launched debugger with a configuration.)
Debugger starts a TIBCO BusinessEvents engine, using parameters provided in the launch configuration, if any were provided.
3.
4.
Use the standard Eclipse commands such as step into (F5), step over (F6), step return, step return, and so on, depending on the level of detail you want to examine.
See the options in the Run menu and in the Breakpoints tab for more options, and use Eclipse help for details.