On a recent client engagement I was asked on my opinions on using mapping tools for XSLT generation. Personally I tend to handcraft most things, although I have used tools for quick generation for example when working in BizTalk.
The question drove up some interesting responses from our internal practices on experiences with several tools across several client sites.
Altova MapForce ( http://www.altova.com/mapforce.html )
- good for large graphical mappings
- pretty flexible about letting you do pretty complex operations on mappings
- Running a scenarios takes more extra clicks
- You cannot apply a scenario to several files.
- XSLT generated is verbose
- No reverse engineering, so xslt overwritten when regenerating the map
- There is also no way to correct stuff like.. the namespace has changed (maybe new version).. as far as it is concerned – it’s a completely different file and you have to start from scratch again
StylusXML ( http://www.stylusstudio.com/ )
- you can run the translation with one of several engines Saxon, Xalan, MSXML, .NET system.xml
- graphical mapping functionality (experience suggests this becomes limited as complexity increases)
- a scenario has to be applied to each file being edited
OxygenXML
-
it runs on Windows, OS X, linux etc.
-
the licensing is per individual, not per machine (i.e. you as an individual can store it on several machines)
-
It also can run translation scenarios, where the XSLT engine (saxon, Xalan, but not Microsoft – out of the box) is part of the scenario set-up.
-
It highlights syntax errors in XSLT, just like spell-checkers. e.g. if you try to use a variable which has not been declared, you get the underline. It is the only product I know that does this.
-
scenarios, when set up can be applied to several files. This is handy , because if you are editing a source XML document (test values), and the actual XSLT, you can apply the same scenario (which source, which xsl, which parser, where to output) without having to set it up for each file you are working on.
Others
Other were tools discussed that were not relevant to my situation:
-
Websphere Transformer Extender (http://www-01.ibm.com/software/integration/wdatastagetx/)
-
Liaison Contivo Analyst (http://www.liaison.com/Products/ContivonbspAnalyst/tabid/57/Default.aspx)
In summary these tools all provide some useful functionality to increase productivity when used in the right scenarios. However this does come with the usual compromise that auto generated code in effect has to be treated as compiled code, or just an initial starting point, unless you have literally 100s of elements to map.
In reality, manual code crafting enables you to make something far more efficient, resusable and extendible than what comes out of a mapper. If you take a bit of time to isolate out things that might change (i.e. parameterize stuff like namespaces that might change in your xpaths). Also mapping tools are should not take away from taking the time to learn the underlying xslt languages.