Making JBoss Fuse, Data Virtualisation and BPMS Work Together – Part 1


Red Hat has been using the phrase “Accelerate, Integrate and Automate”, for sometime now, to explain its comprehensive middleware portfolio to its customers. Red Hat middleware does not work in isolation. It is imperative that these different middleware products can work together to achieve a business outcome.

In this article, I am going to show you how to make the 2 “Integrate” products: JBoss Fuse (Fuse), JBoss Data Virtualisation (JDV) and the “Automate” products: JBoss Business Process Management Suite (BPMS)/JBoss Business Rules Management System (BRMS) work together. Since BPMS/BRMS and JDV run on JBoss Application Server (EAP), I can even claim that this example involves middleware products of all 3 categories ie, Accelerate, Integrate and Automate.

The Business Scenario

The following diagram describes the business scenario:

Integration Use Case
Integration Use Case

A banks receives XML documents from its trading partners. These documents are placed in a specific server’s directory. This example does not cover how the documents get there (maybe via managed FTP or other unspecified means. I shall drag-and-drop files into this directory to test the end product). There are 3 types of XML documents:

  1. A Holdings XML – this is an XML document that contains banking customers other personal holdings (eg, mortgages, cars, etc.) to complete the net-worth picture of customers. More on this later.
  2. A Customer XML – this is an XML document containing customer details that require validation by using Business-Rules-As-A-Service.
  3. A Mortgage Application XML – this is an XML document sent by a partner to start a customer mortgage application. The Mortgage Application business process is running on BPMS.

The Holding XML requires a bit more explanation. Like most organisations, the information regarding a customer and his net worth is not stored in a central place. Instead, one has to go get information in several places to get a complete picture. The data are obtained from 3 data sources:

  1. Account Information including shares ownership (stored in a MySQL database)
  2. Market Data (stock price retrieved using a REST Web Service)
  3. Other Personal Holdings (stored in an XML file which we refer to as a Holdings XML earlier)

The implementation of this business scenario illustrates the following:

  • Use of JBoss Fuse to implement Enterprise Integration Patterns (EIPs) which serve as the linchpin of the solution
  • Use of message queues
  • Use of the graphical data mapper
  • Invoke BPMS’ Business-Rules-As-A-Service running on the Realtime Decision Server
  • Start a Business Process running on the BPMS Execution server from JBoss Fuse
  • Deliver the XML file needed as the 3rd data source (the Holdings XML file) by JBoss Data Virtualisation to provide a consolidated view of customer assets.

Fuse Camel Routes

As stated in the previous section, Fuse Camel routes implementing Enterprise Integration Patterns serve as the linchpin for the whole solution. The main route implementing EIP Content-based Routing is shown below:

Main Route
Main Route
  • Different types of XML documents are distinguished by the attribute named “infoType” of its root element. Here is a description of each route:
  • Other Holdings Route – logs the holdings document and moves it to a target directory to be picked up by JDV
  • Customer Validation Route – logs the xml and put the document in the validateionQueue (for further processing)
  • Home Loan Route – logs the xml, use another EIP called Wire Tap which takes a copy of the message, sends it in an email to designated receivers while the original copy is put in the mortgageQueue (or further processing)
  • Otherwise Route – the document type is not recognised, logs the message and put it in an errorQueue

The Customer Validation Route continues as shown in the diagram below:

Validation Route
Validation Route

The other endpoint picks up the message in the validationQueue, passes the message to a data mapper which converts the xml to a format mandated by the Business-Rules-As-A-Service running on the BPMS Realtime Decision Server. The invocation of the Business-Rules-As-A-Service is performed by a custom bean (BRERemoteValidation task in the diagram). The validation result is logged. The graphical representation of the data mapper is shown below:

Data Mapper
Data Mapper

The Home Loan Route continues with the endpoint shown below:

BPMS Route
BPMS Route

The endpoint picks up the message from the mortgageQueue and uses a custom bean which uses the BPMS Java Remote API to kick off an instance of the mortgage business process using the information contained in the xml.

To Be Continued

In the next installment, I shall describe the Fuse to Business-as-a-service (Business rules application on the Realtime Decision Server) integration which validates the XML data and the Fuse to BPMS integration which kicks off a business process instance for a mortgage application as well as the Fuse to JBoss Data Virtualisation integration. So, stay tuned!