This documentation is for WSO2 Enterprise Service Bus version 5.0.0. For the latest ESB, view the latest WSO2 Enterprise Integrator documentation.

All docs This doc

Versions Compared

Key

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

...

  1. Deploy the following proxy service using instructions in  in Adding a Proxy Service .

    Note the property, <property xmlns:wsa=" http://www.w3.org/2005/08/addressing " name="stockprop" expression="$header/wsa:To"/> in the configuration. It is used to log the value of wsa:To header of the SOAP request. 

    Code Block
    languagehtml/xml
    <proxy xmlns="http://ws.apache.org/ns/synapse" name="StockQuoteProxy" transports="https,http" statistics="disable" trace="disable" startOnLoad="true">
       <target>
          <inSequence>
             <log>
                <property xmlns:wsa="http://www.w3.org/2005/08/addressing" name="stockprop" expression="$header/wsa:To"/>
             </log>
             <send>
                <endpoint>
                   <address uri="http://localhost:9000/services/SimpleStockQuoteService"/>
                </endpoint>
             </send>
          </inSequence>
          <outSequence>
             <send/>
          </outSequence>
       </target>
       <description></description>
    </proxy> 
  2. Send the following StockQuote request using the sample StockQuote client. For information on the sample client, refer to the Sample Clients sub heading in Setting Up the ESB Samples.

    Code Block
    languagexml
    ant stockquote -Daddurl=http://localhost:8280/services/StockQuoteProxy
  3. Note the following message in the ESB log.

    Code Block
    [2013-03-18 14:14:16,356] INFO - LogMediator To: http://localhost:9000/services/SimpleStockQuoteService, WSAction: urn:getQuote, SOAPAction: urn:getQuote, ReplyTo: http://www.w3.org/2005/08/addressing/anonymous, MessageID: urn:uuid:8a64c9cb-b82f-4d6f-a45d-bef37f8b664a, Direction: request,
    stockprop = http://localhost:9000/services/SimpleStockQuoteService

...

  1. Deploy the following proxy service using instructions in Adding a Proxy Service.

    Note the property, <property name="stockprop" expression="$axis2:REST_URL_POSTFIX"/> in the configuration which is used to log the REST_URL_POSTFIX value of the request message. 

    Code Block
    languagehtml/xml
    <proxy xmlns="http://ws.apache.org/ns/synapse" name="StockQuoteProxy" transports="https,http" statistics="disable" trace="disable" startOnLoad="true">
       <target>
          <inSequence>
             <log>
                <property name="stockprop" expression="$axis2:REST_URL_POSTFIX"/>
             </log>
             <send>
                <endpoint>
                  <address uri="http://localhost:9000/services/SimpleStockQuoteService"/>
                </endpoint>
             </send>
          </inSequence>
          <outSequence>
             <send/>
          </outSequence>
       </target>
       <description></description>
    </proxy>
  2. Send the following StockQuote request using the sample StockQuote client. For information on the sample client, refer to the Sample Clients sub heading in Setting Up the ESB Samples.

    Code Block
    languagexml
    ant stockquote -Daddurl=http://localhost:8280/services/StockQuoteProxy/test/prefix
  3. Note the following message in the ESB log.

    Code Block
    INFO - LogMediator To: http://localhost:8280/services/StockQuoteProxy/test/prefix, WSAction: urn:getQuote, SOAPAction: urn:getQuote, ReplyTo: http://www.w3.org/2005/08/addressing/anonymous, MessageID: urn:uuid:ecd228c5-106a-4448-9c83-3b1e957e2fe5, Direction: request, stockprop = /test/prefix

...

  1. Deploy the following proxy service using instructions given in section Adding a Proxy Service.

    Note the property, <property name="stockprop" expression="$trp:Content-Type"/> in the configuration, which is used to log the Content-Type HTTP header of the request message.

    Code Block
    languagehtml/xml
    <proxy xmlns="http://ws.apache.org/ns/synapse" name="StockQuoteProxy" transports="https,http" statistics="disable" trace="disable" startOnLoad="true">
       <target>
          <inSequence>
             <log>
                 <property name="stockprop" expression="$trp:Content-Type"/>
             </log>
             <send>
                <endpoint>
                   <address uri="http://localhost:9000/services/SimpleStockQuoteService"/>
                </endpoint>
             </send>
          </inSequence>
          <outSequence>
             <send/>
          </outSequence>
       </target>
       <description></description>
    </proxy> 

     

  2. Send the following StockQuote request using the sample StockQuote client. For information on the sample client, refer to the Sample Clients sub heading in Setting Up the ESB Samples.

    Code Block
    languagexml
    ant stockquote -Daddurl=http://localhost:8280/services/StockQuoteProxy

     

  3. Note the following message in the ESB log.

    Code Block
    [2013-03-18 12:23:14,101] INFO - LogMediator To: http://localhost:8280/services/StockQuoteProxy, WSAction: urn:getQuote, SOAPAction: urn:getQuote, ReplyTo: http://www.w3.org/2005/08/addressing/anonymous, MessageID: urn:uuid:25a3143a-5b18-4cbb-b8e4-27d4dd1895d2, Direction: request, stockprop = text/xml; charset=UTF-8 

...