Bidirectional Translation Web Services are now available in B2B 11g PS5 Release

Background

In the past, we had received requests from various parties to provide web service based translation capabilities within B2B 11g for going from an XML payload to native one or vice versa. Starting from SOA Suite PS5, this feature is available within the base install. The note here describes the basic usage details, which can then be extended to embed in any other SOA application.

XML To Native

The WSDL definition and the basic test page are available in any basic SOA install at the following URLs:

  • WSDL: http://<Host>:<Port>/b2b/services/XMLToNativeServiceAsString?wsdl
  • Test Page: http://<Host>:<Port>/b2b/services/XMLToNativeServiceAsString

Transaction Set Only

The test page fields that need to be populated are fairly self-explanatory. The screen shot below shows the input values provided, for the document used in the standard sample demo for handling 850 EDI (PO) over AS2.

  • transactionSetOnly: true - This flag defines if the payload will be just the base transaction fields and exclude the envelope or header properties for the exchange.
  • documentTypeName: 850 - This document definition has to exist in the B2B repository as a pre-requisite.
  • documentTypeVersion: 4010 - The version corresponding to the document type specified earlier 
  • payload - The sample XML payload, which typically is passed from a backend application for translation.


The response obtained after invoking the web service with the above-mentioned values is shown below.


As seen in the above screen shot, the translated native EDI payload is returned within the response.

Transaction Set and Envelope Segment

As an extension to the XML to native example shown earlier, the envelope segments can also be generated by changing 2 input fields, namely,

  • transactionSetOnly: false
  • tpName: Remote Trading Partner Name or ID. The assumption here is that a valid, deployed agreement should exist in the repository for the document type, version and the trading partner.
  • XML Payload: Appropriate fields for envelope segments should be specified within the Internal Properties section.


    The response, as mentioned earlier, now includes the envelope segments for the native EDI.

    Native to XML

    The reverse translation is also possible by calling a different web service as shown below.

    • WSDL: http://<Host>:<Port>/b2b/services/NativeToXMLServiceAsString?wsdl
    • Test Page: http://<Host>:<Port>/b2b/services/NativeToXMLServiceAsString

    Transaction Set Only

    We specify similar parameters here, namely,
    • transactionSetOnly: true
    • documentTypeName: 850
    • documentProtocolVersion: 4010
    • payload: EDI payload for only the transaction, without the envelope segments


    The response obtained in this case will be the corresponding XML payload for the EDI.


     It should be noted that the envelope segments cannot be translated for the native to XML web service.

    Further Reading

    To get more details, please refer to this link within the SOA Suite Documentation set.


    Comments:

    Post a Comment:
    • HTML Syntax: NOT allowed
    About


    This is the blog for the Oracle FMW Architects team fondly known as the A-Team. The A-Team is the central, technical, outbound team as part of the FMW Development organization working with Oracle's largest and most important customers. We support Oracle Sales, Consulting and Support when deep technical and architectural help is needed from Oracle Development.
    Primarily this blog is tailored for SOA issues (BPEL, OSB, BPM, Adapters, CEP, B2B, JCAP)that are encountered by our team. Expect real solutions to customer problems, encountered during customer engagements.
    We will highlight best practices, workarounds, architectural discussions, and discuss topics that are relevant in the SOA technical space today.

    Search

    Archives
    « April 2014
    SunMonTueWedThuFriSat
      
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
       
           
    Today