Processing multiple different files into one output message

I have five different excel files (different structure and different data) that will be processed into one output message (XML file). Files arrive into different order , all files are required to create output xml file.

How can I do it in Biztalk ?

more specific questions:

1.Is that possible to aggregate different type of messages in Biztalk and have message with multiple bodies ?

2.Can I aggregate 5 excel files into one message and then execute output pipeline to process all of them ?

Upvotes: 1

Views: 3379

Answers (2)

tom redfern
tom redfern

Reputation: 31780

Agree broadly with Nick's answer above, especially mapping messages in inbound pipelines.

However, I would not implement aggregation via sequential convoy pattern in BizTalk because doing so requires the use of singleton orchestrations, which are a BizTalk anti-pattern (and a support nightmare).

Basic parallel convoys can work because each "set" of 5 inputs will be routed to one instance of an orchestration which will terminate after finishing.

Upvotes: 2

Nick Heppleston
Nick Heppleston

Reputation: 1973

I would approach this problem as follows:

  1. Create a new schema that represents the destination format, we will be mapping the incoming messages into this format.
  2. Create schema's (probably Xml, not flat-file) that represent the incoming Excel spreadsheets. Disassemble the Excel files into their corresponding schema's either through a custom pipeline component (that isn't too difficult using the Excel SDK), or via a third-party tool (such as Farpoint Spread http://www.fpoint.com/biztalk/default.aspx), there is also an open-source component on codeplex at http://excel2007pipeline.codeplex.com/
  3. Map the incoming xml message (disassembled Excel file) on a Receive Port into the destination format created in 1. Multiple Receive Locations can be used on a Receive Port, one for each incoming message format; likewise, multiple Maps can be specified on a Receive Port and the correct map will be selected automatically by BizTalk based on the incoming message type (schema namespace+root node name).

With regards to aggregating messages, take a look at parallel and sequential convoys; with regards to messages with multiple bodies, take a look at multi-part messages - both are out of the scope of this question unless you add further detail around what you are trying to achieve with these concepts.

Upvotes: 3

Related Questions