Apidays New York 2024 - The value of a flexible API Management solution for O...
Integrating with SAP FIX and HL7
1. Integrating with SAP, FIX and HL7
with WSO2 ESB
Isuru Udana
Senior Software Engineer
Sandamal Weerasinghe
Software Engineer
Oct 2014
2. About WSO2
๏ Global enterprise, founded in 2005 by
acknowledged leaders in XML, web
services technologies, standards and
open source
๏ Provides only open source platform-as-a-
service for private, public and hybrid
cloud deployments
๏ All WSO2 products are 100% open
source and released under the Apache
License Version 2.0.
๏ Is an Active Member of OASIS, Cloud
Security Alliance, OSGi Alliance, AMQP
Working Group, OpenID Foundation
and W3C.
๏ Driven by Innovation
๏ Launched first open source API
Management solution in 2012
๏ Launched App Factory in 2Q 2013
๏ Launched Enterprise Store and first
open source Mobile solution in 4Q
2013
4. About the Presenters
๏ Isuru Udana Senior Software Engineer WSO2
๏ Sandamal Weerasinghe Software Engineer WSO2
5. Outline
• Introduction
• Support for integration with ERP systems like SAP and domain specific
protocols like FIX and HL7 in the WSO2 ESB
• Installing and configuring domain specific transports in WSO2 ESB
• Transforming and manipulating message formats with ESB
• Q & A
6. Background
๏ Modern Enterprises
๏ Comprised of so many systems and services
๏ Built based on open standards, custom built, acquired from a third
party, part of a legacy system or any combination of these.
๏ Integration
๏ Organizations are moving away from
MONOLITHIC systems.
๏ Multiple systems connected with SOA
as the blueprint.
10. What is an ESB?
๏ An ESB is a middleware solution that enables interoperability,
among heterogeneous environments using a service oriented
model.
๏ Stateless and Seamless Integration
๏ Standard protocols/formats like SOAP, REST, JSON
๏ Transports like HTTP/S, JMS, TCP, VFS (and many more)
11. WSO2 ESB
• A lightweight, high performance ESB
• Feature rich and standards compliant
• SOAP and WS-* standards
• REST support
• Domain specific protocol support (eg: FIX, HL7)
• User friendly and highly extensible
• 100% free and open source with commercial support
21. Introduction to SAP Adapter
๏ Enables WSO2 ESB to communicate with SAP/R3 systems
๏ Convert R3 (ie:-idoc) message format to external system message
formats.
๏ Allow QoS features
- reliability (ie:-message stores, dead-letter
channels, queues,etc)
- security
22. Introduction to SAP Adapter
๏ Uses popular SAP Java Connector or SAP JCO library
๏ Implemented as a transport
๏ Two modes
- IDOC
- BAPI
28. Configure SAP Adapter
Installing JCO Libraries
๏ Obtain JCO middleware libraries (sapidoc3.jar and sapjco3.jar) from
from your SAP provider
๏ Copy those libraries to <ESB_HOME>/repository/components/lib
directory
๏ Copy the native SAP jco library to the system path
29. Configure SAP Adapter
Setting up JCO Parameters
๏ Copy the SAP endpoint property files to <ESB_HOME>/repository/conf/sap
๏ Two property files
๏ *.dest - SAP endpoint properties when the ESB acts as the
client to an external SAP endpoint
๏ *.server - SAP endpoint properties when the ESB acts as the
server to an external SAP endpoint
30. Configure SAP Adapter
Sample *.dest File
File name : JCOCLIENT.dest
jco.client.lang=en
jco.destination.peak_limit=10
#required - client number
jco.client.client=405
#required - sap password
jco.client.passwd=passwordhere
#required - sap username
jco.client.user=usernamehere
#required - sap system number
jco.client.sysnr=26
jco.destination.pool_capacity=3
#required - sap app server host should be modified as follows..sames as ghost
jco.client.ashost=/H/203.143.18.246/H/155.56.49.28/H/cpccr01
sap.client.RCVPOR=ZWSO2ISR
sap.client.RCVPRT=LS
sap.client.RCVPRN=SAP
31. Configure SAP Adapter
Sample *.server File
File name: JCOSERVER01.server
#required - gateway host should be modified as follows
jco.server.gwhost=/H/203.143.18.246/S/3299/H/155.56.49.28/H/cpccr01
jco.server.connection_count=2
jco.server.progid=JCOSERVER01
jco.server.gwserv=3326
#required - destination properties
jco.server.repository_destination=JCOCLIENT
jco.server.name=JCOSERVER01
jco.server.unicode=1
These parameters should be obtained from your SAP system administrator.
32. Configure SAP Adapter
Configure transports
๏ SAP adapter was written as a new transport for the WSO2 ESB.
๏ This transport consists of two parts as follows.
- BAPI/RFC transport
- IDoc transport
33. Configure SAP Adapter
Configure transports
๏ Enable transports in axis2.xml
- For IDOC transport
Transport Sender
<transportSender name=”idoc” class="org.wso2.carbon.transports.sap.SAPTransportSender"/>
Transport Listener
<transportReceiver name=”idoc” class="org.wso2.carbon.transports.sap.SAPTransportListener"/>
34. Configure SAP Adapter
Configure transports
๏ Enable transports in axis2.xml
- For BAPI transport
Transport Sender
<transportSender name="bapi" class="org.wso2.carbon.transports.sap.SAPTransportSender"/>
Transport Listener
<transportReceiver name="bapi" class="org.wso2.carbon.transports.sap.SAPTransportListener"/>
35. Configuring ESB Artifacts
Receive IDOCs from SAP system
<proxy xmlns="http://ws.apache.org/ns/synapse" name="idoc_proxy" transports="idoc"
startOnLoad="true" trace="disable">
<target>
<inSequence>
<log level="full"/>
<drop/>
</inSequence>
</target>
<parameter name="transport.sap.enableTIDHandler">enabled</parameter>
<parameter name="transport.sap.serverName">JCOSERVER01</parameter>
<parameter name="transport.sap.enableErrorListener">enabled</parameter>
</proxy>
38. Introduction to FIX
๏ Initiated in 1992 for equity trading between 'Fidelity Investment'
and 'Salomon Brothers'
๏ Governed by fixprotocol.org
๏ Is a session oriented communication protocol
https://openclipart.org/detail/170148/stock-quote-graph-by-jhnri4
39. FIX Format
๏ Contains a header, a body and a trailer
๏ Header contains three fields: 8 (BeginString), 9 (BodyLength), and
35 (MsgType).
8=FIX.4.0
<SOH>9=105<SOH>35=D<SOH>34=2<SOH>49=BANZAI<SOH>52=20080711-
06:42:26<SOH>56=SYNAPSE<SOH>
11=1215758546278<SOH>21=1<SOH>38=1000<SOH>40=1<SOH>54=1<SOH
>55=DELL<SOH>59=0<SOH>10=253
40. FIX transport of WSO2 ESB
๏ Based on the Quickfix/J FIX engine
๏ WSO2 FIX transport consists of a receiver and a sender
47. HL7 Message Format
๏ A messaging standard for the exchange, integration, sharing and
retrieval of electronic health information
๏ Non XML
๏ Human readable (ASCII)
๏ Uses segments and one character delimiters
๏ Widely adopted in the Health Care Information Services Industry
around the World
๏ Minimum Lower Layer Protocol
48. HL7 Support of WSO2 ESB
๏ HL7 Feature
๏ MLLP based Transport
๏ HL7 Proxy / Endpoint
๏ Supports HL7 2.x Standard Messages
๏ Transformation
๏ HL7 EDI (application/edi-hl7)
๏ XML
๏ HL7 Message Validation and Conformance Profile Support
49. Exchanging HL7 Messages
๏ HL7 Proxy
๏ MLLP Transport
๏ Capable of listening for HL7 messages
๏ Incoming messages converted into SOAP equivalent
๏ Can manipulate HL7 message using all available ESB mediators
๏ HL7 Endpoint
๏ Capable of sending messages to HL7 receivers
๏ Processing HL7 messages from file system (using VFS)