Yossi Dahan [BizTalk]


Thursday, August 11, 2005

Mapper vs. XSLT

I have what some people may consider a heresy announcment:

I prefer writing custom xslt then using the BizTalk Mapper.

Now, that might not be surprising to some people, but it is definitely surprising me. Especially considering that until two weeks ago I did not have any significat xslt experience.

Of course I know xpath - it comes with the territory - and I know what xslt is, and how it works, but I guess working with BizTalk I simply always defaulted to using the mapper and didn't get to develop my xslt skills. After all - it's visual, It's relativley easy, It's extendible....

Only that its not.

I think when I started with BizTalk, a few years ago now, I was really excited about the mapper, everything seemed so magnificantly simple. You did not need to worry about knowing xslt, xpath, handling namespaces etc.

Then, even when the requirements got more complex (as I gained experience and started seeing the real world of integration out there...) I just added a few more functoids and using the excellent pages feature (that was added in BizTalk 2002) I've split it into pages to make it all clean, nice and more readable...

When things got even more comlex I started calling external assemblies and/or putting in custom xslt bits (which became much easier in BizTalk 2004)

Until one day it hit me - the maps are not really that simple after all (not to mention far from being readable)

So i sat down and shrpened my xslt skill and now, the minute my map stops being a simple link-this-node-to-that-node, I'm moving it all to xslt.

I found out that once I got the hang of it it's quite simple and in my opinion even more readable then a cluttered map with 50 functoids and 17 pages.

Now - Just to make sure nobody get's confused here - I'm still using standard BizTalk map artifacts, which means I'm still doing my transformation as I'd do with a standard map, other then the xslt itself there's no custom code involved, the only difference is that instead of dragging nodes and functoids on the pallete I'm setting the "Custom XSL path" property of my map to an xslt I create in an editor, as shoed here:

Click here for Full size image


  • Hahaha. I've been doing that for years. The Mapper is a good selling point, but the generated XSLT has a lot to be desired. I've been replacing the xslt in my Biztalk 2000/2002 maps.

    By Anonymous Anonymous, at 01/09/2005, 23:57  

Post a comment

<< Home