Defining the ProcessOrder mediation flow
The connections are created to define the mediation flow between the ProcessOrder operation of WebSphere Commerce and the createOrder operation of the External OMS Simulator.
Procedure
- In the Operation connections section of the Mediation Flow Editor, navigate to the ExtOMSSimMediationModule view.
-
Select
. At the bottom of the view, the empty mediation flow diagram for Request:
ProcessOrder is displayed:
- In the mediation flow diagram, right-click a blank spot and select . An XSL Transformation primitive named XSLTransformation1 is added to the mediation flow diagram.
- Select the Properties tab.
- In the Properties view, change the name of the XSL Transformation primitive to ProcessOrder_createOrderRequest.
-
Navigate your mouse cursor over the out terminal of the ProcessOrder :
OrderServicesPortType input node and drag it to the in terminal of the
ProcessOrder_createOrderRequest primitive. A connection between the out
terminal of the ProcessOrder : OrderServicesPortType input node and the in
terminal of the ProcessOrder_createOrderRequest XSL Transformation primitive connection is
created.
-
Repeat the connection process in step 6 to connect the following terminals:
Terminal connections to create From To ProcessOrder_createOrderRequest – out createOrder : ExtOMSSimPartner – in - Double-click the ProcessOrder_createOrderRequest XSL Transformation primitive to create the XML Map and click Finish. This opens the XML Map Editor.
- Navigate your mouse cursor over the left body element where its connector is visible and drag the connector to the body element on the right. A connection between the left body element and the right body element is created.
- Select the Local map transformation.
-
Click the arrow next to the label and select Custom:
- Select the Properties tab.
- In the Properties view, select XSLT.
- Click Browse... and select .
- Click OK.
- Select the BodyToBody template and select body as the value of the body parameter.
- Select .
- Close the XML Map Editor.
- In the Mediation Flow Editor, select the Response: ProcessOrder tab to open its empty mediation flow diagram.
- In the mediation flow diagram, right-click a blank spot and select . An XSL Transformation primitive named XSLTransformation1 is added to the mediation flow diagram.
- Select the Properties tab.
- In the Properties view, change the name of the XSL Transformation primitive to createOrderResponse_AcknowledgeOrder.
-
Repeat the connection process in step 6 to connect the following terminals:
Terminal connections to create From To createOrder : ExtOMSSimPartner – out createOrderResponse_AcknowledgeOrder – in createOrderResponse_AcknowledgeOrder – out ProcessOrder : OrderServicesPortType – in - Double-click the ProcessOrder_createOrderRequest XSL Transformation primitive to create the XML Map and click Finish. This opens the XML Map Editor.
- In the XML Map, repeat the connection process in steps 9 through 18 to create a custom transformation between the body elements using the custom XSL file.
- In the Response: ProcessOrder mediation flow diagram, right-click a blank spot and select .
- Change the name of the Fail primitive to createOrderFailed.
-
Connect the fail terminal of the createOrder : ExtOMSSimPartner callout
response node to the in terminal of the ProcessOrder : OrderServicesPortType
input response node:
- Select to save your changes.