Business Rules Composer

Business Rules Composer in BizTalk360

Published on : Nov 18, 2022

Category : BizTalk Server

Praveena

Author

Introduction

The Business Rules Engine (BRE) in BizTalk Server is a tool provided to configure policies and business rules that need to be satisfied for a business transaction to continue. With BRE, the users can create policies and map them with the BizTalk applications for the process. Using the Business Rules Engine, you can implement business logic that is modular, reusable and simple.  The Business Rules Engine can be a good way to modularize the constantly changing business logic that is often developed inside Orchestrations, making changes a smoother process since updating a policy to the latest version doesn’t require any downtime at all.

Key takeaways

What is Business Rules Engine in BizTalk?

BRE provides a framework that enables users to implement, deploy and version their business logic in a quick and extensible manner. With BRE, the users can define and change business rules without affecting the related application. Based on the business logic, the business rules are created for the application. Consider an example of a loan approval system. The business logic here would be to check for the primary and secondary income of the applicant. That is, if the primary and the secondary income is more than the loan amount, then the loan can be approved. For this, the user will create a rule. The application will create an instance of the policy containing this rule and supply it with data or facts on which to operate.

Creating Business rules using the Business Rules Composer

The Business Rules Composer is a graphical tool for authoring, versioning, and deploying policies and vocabularies. It contains two main parts:

  • The Policy Explorer, where all the rule policies are displayed
  • The Facts Explorer where the data used by the rules is defined
  • Business Rules Engine

The Policy Explorer window allows the users to create policies that contain one or more rules. The rules are created from the vocabularies available in the Facts Explorer, which can be drag-dropped to the Conditions Editor to specify a condition for a rule. The Actions Editor window allows you to specify actions that are executed when the condition evaluates to true. Thus, a policy may contain many rules and each rule can be a combination of multiple conditions and actions.

The rules can be created with conditions that are groupings of logical operators (ANDOR, and NOT). They are applied to predicates that take arguments which are built-in or user-defined fact references. 

Integrating the Business Rules Composer with BizTalk360

BizTalk360 is the one-stop administration and monitoring product which effectively monitors the BizTalk environment. Apart from monitoring, it also has operational capabilities and various portals like BAM, and ESB integrated within. When a business user wants to create a business rule or modify an existing rule, he/she must contact the IT team since the Business Rules Composer that comes with BizTalk Server is too technical. Also, it lacks auditing capabilities, which is an important aspect of security.

To overcome these challenges, we have integrated the Business Rules Composer into BizTalk360. This can be referred to as the web-based Business Rules Composer. With the intuitive UI, business users can easily create policies and rules and modify them. Additionally, all these activities are audited, which gives a clear picture of who has done what.

In BizTalk360, we have added a few more capabilities to the Business Rules Composer – the ‘where’ condition has been added in the Predicate section. This can be used as an argument to retrieve table information and to query database tables. Based on customer feedback, the Business Rules Composer in BizTalk360 was created as a superset of the existing Microsoft Business Rule Composer where instead of just being able to create If, then rules, you can go one level deeper and create If, Then, Else Rules. In fact, you can also create nested “Nested If” conditions if there is a requirement. You will notice multiple rules with the suffix information under each rule.

Business Rules Composer

How to organize a large number of policies in BizTalk Server?

When there are many policies in the Business Rules Composer, the policies would be collapsed in the Policy Explorer. Expanding the policies node will give the list of policies available. In BizTalk360, all the policies are displayed with a scrollbar to scroll between them. Additionally, we have added a search option wherein the user can enter a part or full policy name which lists all the related policies containing the search field data. This helps users to quickly get to the policy they are looking for instead.

Advantages of the Business Rules Composer in BizTalk360

  • BizTalk360 gives a clear view of the policies and vocabularies with a user-friendly interface
  • With the drag-and-drop options, it is amazingly easy to create rules
  • With the if, else and else if options, more nested and complex rules can be created
  • With the effective team management policy, users can be defined access permissions for creating/saving, deploying/publishing the rules
  • Business Rules Composer
  • With the auditing capability, all the user activities will be captured and audited
  • The test results can be downloaded while testing in BizTalk360

Is it possible to use BRE independent of BizTalk Server

BRE is a separate tool coming along with the installation and configuration of the BizTalk Server. For the rules to come into effect, they must be integrated within BizTalk solutions. Hence it is not possible to use BRE independent of BizTalk Server. The policies can be tested with the data that comes from the BizTalk applications.

Get started with BizTalk360 latest version v10.4 today!

Having seen the advantages of using the Business Rules Composer that is integrated with BizTalk360, why not give it a try with the latest version of BizTalk360 v10.4. This version includes many new features and enhancements as per the customer feedback shared. If you have any feedback or looking for any enhancement in a particular module, please feel free to put in your suggestions in the feedback portal.