The amazing world of IBM ODM and more

The amazing world of IBM ODM blog - Angello Manrique Vigil
  • HOME
  • ABOUT ME
  • CONTACT ME

Debugging a simple Ruleflow in Rule Designer

Thursday, 18 May 2017 by Angello Manrique Vigil

There are many ways to test our rules, we can use Excel DVS testsuites, decision operations, web services applications like SoapUI and more, but sometimes we need to debug our ruleflow to find a particular bug that is preventing us to continue. When developing a new rule project in Rule Designer we often need to see the output of our rules without having to deploy our solution and see the behavior of the ruleflow to compare the variables values.

In this article I am going to show how to debug a simple ruleflow using a decision operation to test your Rules.


Steps:

Let’s assume we already have the ruleflow, variables and rules.

  1. Creating the Decision Operation
    • Right click the “deployment” folder in your Rule Project and select New -> Decision Operation.
    • Give a proper name, select the Rule Project and select the Ruleflow inside your Rule Project.
    • Now open your Decision Operation and you should have one like this:Decision Operation sample
    • Click “Define” or to the “Signature” tab.
    • Expand your varible set and drag and drop the corresponding variables to the Input and Output Parameters.
    • Tip: Is a good practice to name your input variable with “Request” at the end and “Response” for your output.decision operation signature sample
  2. Setting the breakpoints
    • There a many places where we can define our breakpoints, it depends on what you need to test and where do you want the flow to stop execution. I will show some examples of places where you can put your breakpoints next.
    • Action Rule:
      • Open your Action Rule, right click in the gray space of any Action line and select “Toggle Breakpoint”breakpoints action rule sample
    • Decision Table:
      • Open your Decision Table, right click in any cell of an Action column and select “Toggle Breakpoint”breakpoint decision table sample
    • BOM member
      • Open a BOM member with BOM to XOM mapping logic, locate the Setter code, right click in the gray space and select “Toggle Breakpoint”breakpoint bom member sample
    • Ruleflow artifacts
      • This is the most common way to debug our Rules, in the ruleflow you can add breakpoints to any task. Select any task, right click and select “Toggle Breakpoint”breakpoint ruleflow sample
  3. Creating the Debug Configuration
    • Navigate to Run -> Debug Configurations… in your Rule Designer top bar.
    • Locate the Decision Operation artifact, right click and select New.
    • Give a proper name and Browse for your Decision Operation.debug configuration sample
    • Tip: The checkbox “Stop at first rule statement” guarantees you enter debug mode if you didn’t set any breakpoints.
    • Now the most important step is to define the “Parameters and Arguments” for this configuration, select the tab and click “Edit Value”.
    • You have to create and return a new object of your Input Parameter class, you can also assign testing values. Click “Function body” and add the proper code. Take a look at my sample:input parameter sample
    • Click Apply and Debug.

Results:

Now you are in Debug mode, watch your variables and step through your code and rules!

debug mode ibm odm sample

I hope you enjoy this article, as always please feel free to contact me about any question or feedback. Thank you!

BOMDebugDecisionOperationJavaRuleDesignerRuleFlow
Read more
  • Published in Debug, Decision Operation, Java, Rule Authoring, Rule Designer, Ruleflow
1 Comment

Recent Posts

  • RPA – UiPath: Working with Excel

    In this blog post we will talk about working wi...
  • ODM on Docker!

    If you are a DevOps enthusiast like me you prob...
  • RPA: UiPath and ODM integration

    In this technical tutorial we will have a look ...
  • Populating Decision Tables with external data sources

    One of the most used artifacts in IBM ODM is th...
  • Decision Composer, integration with Rule Designer

    In this post I will show a new way to start you...
  • Connecting to external Database with ODM API

    The IBM ODM Decision Center and the Rule Execut...
  • Custom log file with ODM API

    Given the positive feedback from previous post ...
  • Working with the Decision Center API

    In many IBM ODM rules implementation projects w...
  • Automating deployments with Ant tasks

    To deploy RuleApps to Rule Execution Server, au...
  • Editing business rules in Microsoft Office

    IBM ODM Decision Center Business Console provid...

Categories

  • Ant Tasks
  • Bluemix
  • Cloud
  • Database
  • Debug
  • Decision Center
  • Decision Operation
  • Decision Table
  • Decision Warehouse
  • Docker
  • Domains
  • Java
  • ODM API
  • RPA
  • Rule Authoring
  • Rule Designer
  • Rule Execution Server (RES)
  • Rule Solutions for Office
  • Ruleflow
  • UiPath

Recent Posts

  • RPA – UiPath: Working with Excel

    In this blog post we will talk about working wi...
  • ODM on Docker!

    If you are a DevOps enthusiast like me you prob...
  • RPA: UiPath and ODM integration

    In this technical tutorial we will have a look ...
  • Populating Decision Tables with external data sources

    One of the most used artifacts in IBM ODM is th...
  • Decision Composer, integration with Rule Designer

    In this post I will show a new way to start you...

Recent Comments

  • Mastan on Debugging a simple Ruleflow in Rule Designer
  • Angello Manrique Vigil on ODM on Docker!
  • brian on ODM on Docker!
  • Angello Manrique Vigil on Populating Decision Tables with external data sources
  • Pramod on Populating Decision Tables with external data sources

Subscribe

  • Register
  • Log in
  • Entries RSS
  • Comments RSS
  • WordPress.org

All rights reserved. Made by Angello Manrique Vigil.

TOP