A project team with Superior Stamping has chosen to
expose the Order Fulfillment orchestration as an ASMX Web service. The
orchestration receives three different message types grouped into the OrderFulfillmentPort, as shown in Figure 1.
The BizTalk Web
services Publishing Wizard is used to create a Web service with three
service operations from the port definition. Figure 2 shows the summary page for the ASMX service.
The
created Web service embeds the request type from each of the three
one-way operations in another XML element with the name of the
operation. For example, an XML document for the request of the JobCompletion operation, as defined by the BizTalk message schema, may be created as follows:
Example 1.
<Completion xmlns= "http://SuperiorStamping.Fulfillment.JobCompletion"> <OrderId xmlns="..."> o-1234 </OrderId> <CompletedAt xmlns="..."> 2011-10-16 </CompletedAt> </Completion>
|
Publishing the port as a Web service adds a JobCompletion element around the message, as shown here:
Example 2.
<soap:Body>
<JobCompletion xmlns=
"http:// SuperiorStamping.Fulfillment/Service">
<Completion xmlns=
"http://SuperiorStamping.Fulfillment.JobCompletion">
<OrderId xmlns="...">
o-1234
</OrderId>
<CompletedAt xmlns="...">
2011-10-16
</CompletedAt>
</Completion>
</JobCompletion>
</soap:Body>