Promoting Properties with the BizTalk Mapper

Well, almost.

With a little help of the Flat File Disassembler or the Xml Disassembler component.

Property promotion is a core concept in BizTalk and its understanding is essential to leverage the publish/subscribe mechanism at the heart of the BizTalk messaging engine.

As a recent Certified Specialist, I believed I new everything there was to understand about property promotion in BizTalk. During a training session for our potential customers, I literally discovered what must be little known feature of BizTalk.

As you know, property promotion happens during the pipeline processing for inbound messages. Namely, one must either use the Xml Disassembler or the Flat File Disassembler pipeline component. In either case, an association must be established between an element or a attribute from the expected inbound schema to the corresponding property in the Property Schema.

Well, this is a simplified view, but bear with me. I’m not talking about correlation here, for simplifying purposes.

As it turns out, the property to promote does not have to actually come from a value found in the body of the message that the Flat File Disassembler converts to an Xml message. In fact, the Flat File Disassembler and Xml Disassembler pipeline components are also capable of promoting a property, as long as this property exists at one stage in the downstream processing of the inbound pipeline.

Yes, you read that right.

The practical thing here, is that we can configure a property to be promoted from any given schema, different than the one used in the very same pipeline for disassembling flat files.

Promoting Properties with the BizTalk Mapper

If your head did not blow up at this stage, let’s explain how one can leverage this feature in a useful scenario. A simple way to use this feature is to create a document conforming to the schema from which to promote properties directly in a BizTalk map configured on the receive port.

What’s important to mention here, is that the property we want to promote does not even exist at the time the disassembler component performs its processing on the incoming message. I discovered this feature while inadvertently trying to promote a property in the target schema of a Flat File dissassembled input document. Only to discover that it actually worked !

As I mentioned, the diagram above is one possible scenario. This also works with the Xml Disassembler. This gives me a good idea for a generic Promoter component…

All in all, pretty neat feature that I will use frequently from now on!

This entry was posted in BizTalk. Bookmark the permalink.