12,063,645 members (68,088 online)
I have noticed that BizTalk role-links are not used by developers due to the lack of understanding about it. This article attempts to allay the fears of using role-links in BizTalk. Role-links are not BAS and need not use BAS.
A mail order company sends several packages to different destinations. The mail order company uses several
shippers for this purpose. For example FEDEX, UPS and USPS. Every shipper covers certain destination
Zip codes due to proximity of the airports or special delivery processes. The
Shippers destination zip code coverages keep changing during different seasons (spring/summer/fall/winter).
zip codes covered by the various shippers keep changing due to various conditions.
shipperscan be easily changed without storing the specific
shippercan be done easily.
Role in BizTalk parlance comprises of a port-type using which all the messages are sent out from an orchestration. Using one role, several parties can be attached to it. In the case under consideration, we have a
Shipper role and several
parties (FEDEX, UPS and USPS) attached to it.
role-link can be used to abstract a business process from an actual execution/delivery system. For example in the mail order system, the goal is to send a package to a customer, by hiring an intermediary, a shipper. Every shipper requires data to be sent in a certain format.
Party is an
entity or a
business or an
enterprise outside the boundary of BizTalk to which the data is transmitted. One must
role-link with a party in order for it to work.
Parties are bound to a
Role, as in our case, the
ZipCode field is compared in every party and the message is transmitted to the one which matches it.
ShipOrders orchestration uses a
ZipCodeShipper) and a
Shipper) to send the package
ZipCode information to various
Parties attached to its Role.
ZipCodeShipper(Microsoft.XLANGs.BaseTypes.DestinationParty) = new Microsoft.XLANGs.BaseTypes.Party(MailOrderMsg.Body.ShippingZipCode, "ZipCode");
The party takes two parameters, the first is the
name and the other is the
qualifier. Notice how the destination party is set, by providing the
zipcode value and the
NOTE that the
ShippingZipCode is the promoted field.
MailOrderProcessing: Destination party not found while attempting to send message '
MailOrderMsg' to (94553, ZipCode).
Resolution: This could happen when the shipper role does NOT have this
Zipcode in its delivery list. One of the enlisted parties must have this
ZipCode added, this could fix the issue.
The BizTalk Party configuration is left as an exercise to the developer.