[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] XML/XSLT for web templating


Subject: Re: [xsl] XML/XSLT for web templating
From: Robert Koberg <rob@xxxxxxxxxx>
Date: Mon, 08 Oct 2007 14:46:34 -0400

On Mon, 2007-10-08 at 10:11 -0400, Alessandro Bologna wrote:
> 1. Too slow (i proved it wrong already, but still, just yesterday  
> somebody was telling about Freemarker being 15 times faster than XSLT  
> at rendering docbook, and I know that Robert Koberg has something to  
> say about that... :)

Yea, that was a fun exercise... I think I proved clearly that freemarker
is not 15 times faster. It is indeed slower AND much more complicated.
Basically, you cannot compare the two. They are different beasts.
Anybody who claims freemarker is 15 times faster simply does not know
what they are talking about. And risking a Revulsky infestation, I don't
think even he claims that anymore.

In freemarker, you have to write a java driver for your transformation.
In other words, you have to write custom java so the freemarker
'transformation' code knows what to do. This has to be written for each
XML structure/schema you use. If I remember correctly, this was about
450 lines for freemarker's handling of a small subset of docbook. Then,
you have to understand and know the driver's API to write the templates.
When you use XSL you just write XSL.

It looks like you have a really nice system set up. It is too bad your
teammates can't or won't see it.

One thing you might consider is pre-generating the pages with sprinkles
of Velocity/Freemarker thrown in for the truly dynamic runtime
requirements. This way you can get a kind of caching and let the runtime
templating library do only as much work as it needs.

best,
-Rob


Current Thread
Keywords