Saturday, August 16, 2014

OSB 12c Templates for Proxy Pipeline

Oracle Service Bus allows mediation and manage the interactions between disparate systems through a common canonical model & messaging infrastructure. Though the product provide enriched tools to orchestrate complex integration requirements, generally it is  meant for virtualising the interactions between different applications and hence most of the time follows a predictable orchestration pattern in the message flow. In 11g, we have to model these repeatable message flows in every proxy and with 12c we don't need to do that anymore. Luckily with 12c, we have the Proxy Pipeline templates, which allows us to model these repeatable message flows into a template and let the concrete Piplelines generated out of it.

As a first example, we will model a Pipeline Template for a WSDL based message interaction.







Lets take a look at the design palette for the message flow. The highlighted section in the below image shows the placeholders that can be added to the template to provide overriding capability to the concrete pipeline. 



Nodes - Placeholders for Pipeline pair, Branch & Route nodes.
Stages - Placeholders for one or more Stages, which in turn can contain actions.
Actions - Placeholders for one or more Actions.
Route - Placeholder for Route node.
Conditional  - Placeholder for a Conditional Branch
Operational - Placeholder for a Operational Branch

The example template acts as the core template for any WSDL based pipeline and includes the below capabilities :
1)Mapping EBMHeader(Ex:- AIA) information to shared variables to make reporting more meaningful to handle the message correlation. (i.e) the keys can be derived from the information available in the header.
2)Report Request & Response payloads
3)Placeholder for a Operational Branch and create a placeholder route action fora a valid business/proxy service in the available branch.
4)Provide a common error handling pattern.

The final template would like below :


The shared variables ebmID & entity key will hold the EBMID(from AIA Header) &  entity specific id from the business entity respectively. They will acts as the keys for the reporting. Also, another feature in templates is that you can lock  a particular action from being changed at the concrete pipeline.


Lets generate a concrete pipeline:







On clicking the finish button, the generated concrete pipeline/proxy will look like below :





The placeholders are now turned concrete and we can add more components into as per required.

For some reason if we think we need to break the template link, then we can go to Pipeline -> Configuration -> click on the 'Break Template Link' button as shown  below:


Breaking the template link will retain only the concrete elements in the pipeline. We need to be careful as breaking the template link will automatically save the changes (though there will be a warning popup shown to confirm the changes).. there is no going back as far as I could see..

No comments:

Post a Comment