Martijn's blog - E-Commerce, EAI, BizTalk and .NET


Untyped Message Processing and external projects

Have you ever used untyped messages send to a general Orchestration (error handling, general processing, etc)?

If you have, you've probably casted the outbound message into a variable of type System.Xml.XmlDocument and passed that to the called or started Orchestration...

However, if you factor out the general orchestration to enable reuse from other projects, you are no longer able to do this.

Instead, BizTalk wraps your Orchestration parameter into a type called Microsoft.XLANGs.RuntimeTypes.XmlDocumentSerializationProxy, which enables serialization of type System.Xml.XmlDocument, as it's missing the Serializable attribute. It does this outbound only, so you need to perform a few steps to get your Orchestration call back online:

1) reference Microsoft.XLANGs.RuntimeTypes.dll from the Microsoft BizTalk Server 2004 installation folder into both projects;

2) change your general Orchestration (the one factored out) to have a your Orchestration parameter as type Microsoft.XLANGs.RuntimeTypes.XmlDocumentSerializationProxy instead of System.Xml.XmlDocument (otherwise, the types won't match and VS.NET won't let you compile ;-) );

3) change your calling Orchestration to have a variable of type Microsoft.XLANGs.RuntimeTypes.XmlDocumentSerializationProxy instead of System.Xml.XmlDocument and set your Expression shape to do this:

GeneralConfirmation = new Microsoft.XLANGs.RuntimeTypes.XmlDocumentSerializationProxy(ConfirmAccount);

3) compile the external referenced project;

4) reconfigure your Call Orchestration or Start Orchestration shape.

Now your Orchestration will function correctly, just like before. The difference being able to reuse the general Orchestration originally contained within the same project.


Suppressing automatic message splitting

If you have BizTalk automatically splitting up inbound messages and want to suppress this behaviour, set the maxOccurs property to "*" (unbounded) for any repeating structure you don't want BizTalk splitting up on:

<xs:element name="Journal">


<xs:element maxOccurs="unbounded" name="Journal">

BizTalk Performance - dedicated blog from Microsoft!

Finally, an answer to many customer questions....:


Kind words from Microsoft, I'm a MVP awardee

I just wanted to let everyone know I've been awarded the Microsoft Most Valuable Professional award for BizTalk Server. I couldn't be happier at the moment :-D