Skip to main content

Summary This article clarifies how to specify a SOAP/HTTP endpoint as a callback for a CORBA backend when using the Orbix WebServices routing component.
Environment

Orbix 6.3.6

All Supported Operating Systems

Question/Problem Description

How to pass a SOAP/HTTP callback reference to an Orbix WebServices router for a CORBA backend?

Passing SOAP/HTTP endpoint references to an Orbix WebServices router in front of a CORBA server.

Clarifying Information

Assume the following scenario.

You need to expose a CORBA backend application to SOAP/HTTP Web Services clients through an Orbix WebServices router and the IDL for the CORBA backend defines that a reference (callback reference) needs to be passed into method calls. The WSDL generated out of the IDL will contain EndpointReferenceType types as input parameters.

The Orbix WebServices router proxifies transient references when a reference is passed from the client to the backend server or vice versa. This proxy is then used to invoke the methods and apply the protocol conversion (SOAP/HTTP <-> CORBA)

This article clarifies how to pass in SOAP/HTTP callback reference, so that the Orbix WebServices router is able to proxify it and so that a CORBA backend application is able to call back on the Web Services SOAP/HTTP client.

The above scenario is common in a publish-subscribe type of application.

In order to quickly test a SOAP/HTTP method exposed by the router a tool like SoapUI is being used.

Error Message
Defect/Enhancement Number
Cause
Resolution

On the client SOAP/HTTP side there are two mandatory pieces of information necessary in the SOAP message in order for the Artix router to be able to proxify a callback reference:

  • the Address element containing the HTTP address and
  • the Metadata element, containing the wsdlLocation attribute and the ServiceName element

Below is an example.

Assuming the IDL is defined as follows in pubsub.idl

interface Subscriber {
    void notify (in string message);
};

interface Publisher {
    void registerSubscriber(in Subscriber subscriber);
};   


When using SoapUI and loading the WSDL generated out of the IDL by the Orbix compiler with

    idl -wsdl pubsub.idl

the sample request for the registerSubscriber message will need to look like below:

<soapenv:Envelope
  xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xmlns:pubsub="http://schemas.iona.com/idltypes/pubsub.idl"
  xmlns:add="http://www.w3.org/2005/08/addressing">
  <soapenv:Body>
    <pubsub:Publisher.registerSubscriber>
      <subscriber>
        <add:Address>http://localhost:10000/Subscriber</add:Address>
        <add:ReferenceParameters></add:ReferenceParameters>
        <add:Metadata
          m3:wsdlLocation="file:/C:/test/pubsub.wsdl"
          xmlns:m3="http://www.w3.org/2006/01/wsdl-instance">
          <m4:ServiceName xsi:type="m4:ServiceNameType"
          xmlns:m4="http://www.w3.org/2005/02/addressing/wsdl"
          xmlns:m5="http://schemas.iona.com/idl/zcorpublish.idl">m5:SubscriberSOAPService</m4:ServiceName>
        </add:Metadata>
      </subscriber>
    </pubsub:Publisher.registerSubscriber>
  </soapenv:Body>
</soapenv:Envelope>

Once the above message is passed through the Orbix WebServices routing component, it will get proxified and the CORBA backend will be able to invoke notify calls on this proxy. These calls will be translated into SOAP/HTTP requests by the router and invoked on the SOAP/HTTP callback endpoint exposed by the client.

Workaround
Notes
Attachment

#KnowledgeDocs
#Orbix