< Previous

Building the response flow

Transform the message so that it matches the requester and provider interfaces.

  1. Click on the Response tab to switch to the response flow canvas.
  2. Select an XSL Transformation primitive from the palette, drop it onto the request flow canvas, and name it TransformToStockQuoteRequester.
  3. In the response flow canvas, wire the output terminal of Callout Response - getStockQuote : StockQuoteServicePartner to the input terminal of TransformToStockQuoteRequester.
  4. Wire the output terminal of TransformToStockQuoteRequester to the input terminal of Input Response - getQuote : StockQuoteService.
    Wired response flow
  5. Set the properties for the XSL Transformation primitive TransformToStockQuoteRequester:
    1. Select the TransformToStockQuoteRequester primitive in the response flow canvas. Switch to the Details tab in the Properties view.
    2. Click on the New button next to the Mapping File field. In the Specify Message Types wizard, change the Root field to /. Click Finish.
    3. In the Source section of the mapping editor, expand tns:smo > context > correlation [0..1] and tns:smo > body [0..1] > getStockQuoteResponse. In the Target section, expand tns:smo > body [0..1] > getQuoteResponse.
    4. Click on customerID [0..1] in the context section of the Source, then click on customerID in the body section of the Target. Right-click, and select Create Mapping. This action maps the value of the customerID in the message body to the correlation context
    5. Click on stockValue in the Source, then click on value in the Target. Right-click, and select Create Mapping.
    6. To map the remaining fields, click on smo in the Source, then click on smo in the Target. Right-click, and select Match Mapping. All remaining fields should now be mapped.
      Mapping editor
    7. Save your changes and close the mapping editor.
    8. The mapping file and its associated XSL appear in the properties view of the primitive.
      Details panel
    9. Save your changes in the mediation flow editor.

Feedback
(C) Copyright IBM Corporation 2005, 2006. All Rights Reserved.
< Previous