none
BizTalk Orchestration - Schema Design Question RRS feed

  • Question

  • We are new to BizTalk Orchestration. We have a requirement to create an orchestration in BizTalk 2010 which involves 3 WCF services (Create Order, Create Invoice, and Process Payment). Our LOB application would initiate the Orchestration. The Orchestration should call the WCF services in a sequential fashion and return the response to LOB application. Please see below:

    LOB-è Create Order èCreate InvoiceèProcess PaymentèReturn Response to LOB

    Here is the simplified WCF operation contract (Not depicting the return values to keep it simple)

    1. CreateOrder (CustomerID, OrderLineItem)
    2. Create Invoice (OrderID, InvoiceLineItem)
    3. ProcessPayment  (PaymentType, CreditCardInfo)

    For the above requirement, we need to know how to design the schemas in BizTalk to receive the message required for the Orchestration. If you look at the sequence, the Payment information is needed as the final step in the Orchestration.   We need to decide how the Orchestration would receive the message required to process payment.  (The payment information comes from LOB). Should we receive the Order and Payment information as a single message and map them to the appropriate service?  Any inputs in this regard will be much appreciated.

    Thursday, September 1, 2011 4:59 PM

Answers

  • I would create a schema for order and a schema for payment, and then use them in a multi-part message. When you get your information back from the WCF services construct a message with one or more maps using the other messages.  The nice thing about breaking it in to one map per source message is that it is easier to maintain, if you have a schema change you only have to rebuild maps.  The downside is that more maps will perform more slowly than a single map. 

     

    One thing in BizTalk that bugs me is that a schema change that changes the nesting level of a record blows out all of the links in a map, and they have to be recreated.  So if schemas are going to change I try to isolate each map to one schema, and do multiple mappings within one construct message, to cut down the size of a map if I have to rebuild it.  


    Down there somewhere, its just ones and zeros.
    • Marked as answer by arasheed Thursday, September 1, 2011 7:23 PM
    Thursday, September 1, 2011 6:30 PM

All replies

  • Hi,

    I would suggest to an enricher pattern, see for example this article on codeproject. By calling each subsequent service you can enrich message with necessary information before sending it to LOB system.

    HTH

    Regards,

    Steef-Jan Wiggers
    MVP & MCTS BizTalk Server 2010
    http://soa-thoughts.blogspot.com/
    If this answers your question please mark it accordingly


    BizTalk
    Thursday, September 1, 2011 6:23 PM
    Moderator
  • I would create a schema for order and a schema for payment, and then use them in a multi-part message. When you get your information back from the WCF services construct a message with one or more maps using the other messages.  The nice thing about breaking it in to one map per source message is that it is easier to maintain, if you have a schema change you only have to rebuild maps.  The downside is that more maps will perform more slowly than a single map. 

     

    One thing in BizTalk that bugs me is that a schema change that changes the nesting level of a record blows out all of the links in a map, and they have to be recreated.  So if schemas are going to change I try to isolate each map to one schema, and do multiple mappings within one construct message, to cut down the size of a map if I have to rebuild it.  


    Down there somewhere, its just ones and zeros.
    • Marked as answer by arasheed Thursday, September 1, 2011 7:23 PM
    Thursday, September 1, 2011 6:30 PM