Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. Download and install the ESB profile of WSO2 Enterprise Integrator (EI). For a list of prerequisites and step-by-step installation instructions, go to Installing the Product in WSO2 EI Documentation.
  2. Start an instance of Sample Axis2 server. For instructions, go to Starting the Axis2 server in WSO2 EI Documentation.
  3. Deploy the back-end service SimpleStockQuoteService. For instructions on deploying sample back-end services, go to Deploying sample back-end services in WSO2 EI Documentation.
  4. Download Return-Address.zip file.

ESB configuration

Start the ESB profile and log into its Management Console. For instructions, see Starting the ESB profile in WSO2 EI Documentation.

...

  1. Execute the following command to send a request using the Stock Quote Client to the ESB profile: 

    For information on the Stock Quote Client and its operation modes, go to Stock Quote Client in the WSO2 EI Documentation.

    ant stockquote -Daddurl=http://localhost:9000/soapservices/SimpleStockQuoteService -Dtrpurl=http://localhost:8280/services/ReturnAddressProxy -Dmode=dualquote -Dsymbol=fooFor information on the Stock Quote Client and its operation modes, go to Stock Quote Client in the WSO2 EI Documentation.

  2. If you use TCPmon to analyze the message passing, you will notice that the client sends the following message. Note that in line 4, the WS-Addressing ReplyTo header is set to a service called anonService2. Since the reply is made to this service on a separate channel, the client will receive no response.

    Code Block
    languagehtml/xml
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
          <soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing">
             <wsa:To>http://localhost:9000/service/SimpleStockQuoteService</wsa:To>
             <wsa:ReplyTo>
                <wsa:Address>http://10.150.3.53:8200/axis2/services/anonService2/</wsa:Address>
             </wsa:ReplyTo>
             <wsa:MessageID>urn:uuid:9aa8e783-2eb7-4649-9d36-a7fb3ad17abd</wsa:MessageID>
             <wsa:Action>urn:getQuote</wsa:Action>
          </soapenv:Header>
          <soapenv:Body>
             <m0:getQuote xmlns:m0="http://services.samples">
                <m0:request>
                   <m0:symbol>foo</m0:symbol>
                </m0:request>
             </m0:getQuote>
          </soapenv:Body>
       </soapenv:Envelope> 

    Axis2 Client Response:

    Standard dual channel :: Stock price = $78.11501844382737

    Axis2 Server Response:

    samples.services.SimpleStockQuoteService :: Generating quote for : foo

How the implementation works

...