64
Integrating with SAP, FIX and HL7 with WSO2 ESB Isuru Udana Senior Software Engineer Sandamal Weerasinghe Software Engineer Oct 2014

Integrating with SAP FIX and HL7

  • Upload
    wso2

  • View
    263

  • Download
    8

Embed Size (px)

DESCRIPTION

-

Citation preview

Page 1: Integrating with SAP FIX and HL7

Integrating with SAP, FIX and HL7with WSO2 ESB

Isuru UdanaSenior Software Engineer

Sandamal WeerasingheSoftware Engineer

Oct 2014

Page 2: Integrating with SAP FIX and HL7

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

Page 3: Integrating with SAP FIX and HL7

What WSO2 delivers

Page 4: Integrating with SAP FIX and HL7

About the Presenters

๏ Isuru Udana Senior Software Engineer WSO2

๏ Sandamal Weerasinghe Software Engineer WSO2

Page 5: Integrating with SAP FIX and HL7

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

Page 6: Integrating with SAP FIX and HL7

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.

Page 7: Integrating with SAP FIX and HL7

Background๏ Service Integration

Page 8: Integrating with SAP FIX and HL7

Background๏ Spaghetti Integration

What about maintainability, scalability, troubleshooting and governance?

Page 9: Integrating with SAP FIX and HL7

Background๏ ESB in Action

Page 10: Integrating with SAP FIX and HL7

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)

Page 11: Integrating with SAP FIX and HL7

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

Page 12: Integrating with SAP FIX and HL7

Key Features - Routing

Page 13: Integrating with SAP FIX and HL7

Key Features - Filtering

Page 14: Integrating with SAP FIX and HL7

Key Features - Transformation

Page 15: Integrating with SAP FIX and HL7

Key Features - Protocol Switch

Page 16: Integrating with SAP FIX and HL7

Key Features - Load Balancing

Page 17: Integrating with SAP FIX and HL7

Key Features - Quality of Service

Page 18: Integrating with SAP FIX and HL7

Integrating WSO2 ESB with SAP

Page 19: Integrating with SAP FIX and HL7

Introduction to SAP Adapter

Page 20: Integrating with SAP FIX and HL7

Introduction to SAP Adapter

Interconnects SAP R/3 with external Systems

Page 21: Integrating with SAP FIX and HL7

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

Page 22: Integrating with SAP FIX and HL7

Introduction to SAP Adapter

๏ Uses popular SAP Java Connector or SAP JCO library

๏ Implemented as a transport

๏ Two modes

- IDOC

- BAPI

Page 23: Integrating with SAP FIX and HL7

Use casesSending IDOC messages to SAP

Page 24: Integrating with SAP FIX and HL7

Use casesReceiving IDOC messages from SAP

Page 25: Integrating with SAP FIX and HL7

Use casesInvoking BAPI Functions

Page 26: Integrating with SAP FIX and HL7

Use casesStore and Forward - Guaranteed Delivery

Page 27: Integrating with SAP FIX and HL7

Use casesIntegrating with Multiple Systems

Page 28: Integrating with SAP FIX and HL7

Configure SAP Adapter

๏ 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

Installing JCO Libraries

Page 29: Integrating with SAP FIX and HL7

Configure SAP Adapter

๏ 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

Setting up JCO Parameters

Page 30: Integrating with SAP FIX and HL7

Configure SAP Adapter

Sample *.dest File

File name : JCOCLIENT.dest

jco.client.lang=enjco.destination.peak_limit=10#required - client numberjco.client.client=405#required - sap passwordjco.client.passwd=passwordhere#required - sap usernamejco.client.user=usernamehere#required - sap system numberjco.client.sysnr=26jco.destination.pool_capacity=3#required - sap app server host should be modified as follows..sames as ghostjco.client.ashost=/H/203.143.18.246/H/155.56.49.28/H/cpccr01sap.client.RCVPOR=ZWSO2ISRsap.client.RCVPRT=LSsap.client.RCVPRN=SAP

Page 31: Integrating with SAP FIX and HL7

Configure SAP Adapter

Sample *.server File

File name: JCOSERVER01.server

#required - gateway host should be modified as followsjco.server.gwhost=/H/203.143.18.246/S/3299/H/155.56.49.28/H/cpccr01jco.server.connection_count=2jco.server.progid=JCOSERVER01jco.server.gwserv=3326#required - destination propertiesjco.server.repository_destination=JCOCLIENTjco.server.name=JCOSERVER01jco.server.unicode=1

These parameters should be obtained from your SAP system administrator.

Page 32: Integrating with SAP FIX and HL7

Configure SAP Adapter

๏ 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

Configure transports

Page 33: Integrating with SAP FIX and HL7

Configure SAP Adapter

๏ 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"/>

Configure transports

Page 34: Integrating with SAP FIX and HL7

Configure SAP Adapter

๏ 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"/>

Configure transports

Page 35: Integrating with SAP FIX and HL7

Configuring ESB Artifacts

<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>

Receive IDOCs from SAP system

Page 36: Integrating with SAP FIX and HL7

Configuring ESB Artifacts

<proxy xmlns="http://ws.apache.org/ns/synapse" name="BAPIProxy" transports="http"

startOnLoad="true" trace="disable">

<target>

<inSequence>

<payloadFactory media-type="xml">

<format>

<bapirfc xmlns="" name="STBAPI_COMPANYCODE_GETLI"/>

</format>

</payloadFactory>

<send>

<endpoint>

<address uri="bapi:/JCOCLIENT"/>

</endpoint>

</send>

</inSequence>

</target>

</proxy>

Invoke BAPI functions

Page 37: Integrating with SAP FIX and HL7

WSO2 ESB and FIX

Page 38: Integrating with SAP FIX and HL7

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

Page 39: Integrating with SAP FIX and HL7

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

Page 40: Integrating with SAP FIX and HL7

FIX transport of WSO2 ESB

๏ Based on the Quickfix/J FIX engine

๏ WSO2 FIX transport consists of a receiver and a sender

Page 41: Integrating with SAP FIX and HL7

Bridge FIX to HTTP

Page 42: Integrating with SAP FIX and HL7

Switch from FIX to JMS

Page 43: Integrating with SAP FIX and HL7

Switch from JMS to FIX

Page 44: Integrating with SAP FIX and HL7

Switch between FIX Versions

Page 45: Integrating with SAP FIX and HL7

CBR (Content Based Routing)

Page 46: Integrating with SAP FIX and HL7

WSO2 ESB and HL7

Page 47: Integrating with SAP FIX and HL7

๏ 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

HL7 Message Format

Page 48: Integrating with SAP FIX and HL7

๏ 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

HL7 Support of WSO2 ESB

Page 49: Integrating with SAP FIX and HL7

๏ 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)

Exchanging HL7 Messages

Page 50: Integrating with SAP FIX and HL7

๏ Immediate ACK

HL7 Message Flows

Client ESB HL7 Proxy Server

1

<proxy>...<parameter name="transport.hl7.AutoAck">true</parameter></proxy>

Page 51: Integrating with SAP FIX and HL7

๏ Immediate ACK

HL7 Message Flows

Client ESB HL7 Proxy Server

1

2 ACK

<proxy>...<parameter name="transport.hl7.AutoAck">true</parameter></proxy>

Page 52: Integrating with SAP FIX and HL7

๏ Immediate ACK

HL7 Message Flows

Client ESB HL7 Proxy Server

1

2 ACK3

<proxy>...<parameter name="transport.hl7.AutoAck">true</parameter></proxy>

Page 53: Integrating with SAP FIX and HL7

๏ Application ACK

HL7 Message Flows

Client ESB HL7 Proxy Server

1

<proxy>...<parameter name="transport.hl7.AutoAck">false</parameter><inSequence>...<property name="HL7_APPLICATION_ACK" value="true" scope="axis2"/>

</inSequence> </proxy>

Page 54: Integrating with SAP FIX and HL7

๏ Application ACK

HL7 Message Flows

Client ESB HL7 Proxy Server

12

<proxy>...<parameter name="transport.hl7.AutoAck">false</parameter><inSequence>...<property name="HL7_APPLICATION_ACK" value="true" scope="axis2"/>

</inSequence> </proxy>

2

Page 55: Integrating with SAP FIX and HL7

๏ Application ACK

HL7 Message Flows

Client ESB HL7 Proxy Server

12

3 ACK

<proxy>...<parameter name="transport.hl7.AutoAck">false</parameter><inSequence>...<property name="HL7_APPLICATION_ACK" value="true" scope="axis2"/>

</inSequence> </proxy>

2

Page 56: Integrating with SAP FIX and HL7

Transforming and manipulating message formats with ESB

Page 57: Integrating with SAP FIX and HL7

Transforming Message Formats

Page 58: Integrating with SAP FIX and HL7

๏ Payload Factory Mediator

๏ XSLT Mediator

๏ Script Mediator

๏ Smooks Mediator

๏ Enrich Mediator

Transformation Mediators

Page 59: Integrating with SAP FIX and HL7

๏ For simple transformations

๏ Replaces the contents of a message

๏ Payload formats - XML or JSON

Payload Factory Mediator

Page 60: Integrating with SAP FIX and HL7

Payload Factory Mediator<p:getquote xmlns:p="http://services.

samples">

<p:request>

<p:symbol>WSO2</p:symbol>

</p:request>

</p:getquote>

<p:getquote xmlns:p="http://services.

samples">

<p:request>

<p:code>WSO2</p:code>

</p:request>

</p:getquote>

<payloadFactory media-type="xml">

<format>

<m:getQuote xmlns:m="http://services.samples">

<m:request>

<m:symbol>$1</m:symbol>

</m:request>

</m:getQuote>

</format>

<args>

<arg xmlns:m0="http://services.samples" expression="//m0:Code"/>

</args>

</payloadFactory>

INPUT OUTPUT

CONFIG

Page 61: Integrating with SAP FIX and HL7

๏ For advanced transformations

๏ Transforms using a XSLT script

XSLT Mediator

Page 62: Integrating with SAP FIX and HL7

QnA

Page 63: Integrating with SAP FIX and HL7

Business Model

Page 64: Integrating with SAP FIX and HL7

Contact us !