cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Fagerstrom <>
Subject Streaming Transformations for XML (STX) and Cocoon
Date Wed, 19 Feb 2003 14:25:45 GMT
I have done some initial experiments using STX (Streaming 
Transformations for XML see: ) together with 
Cocoon and this far it seem to work well.

STX is similar to XSLT but the transformation rules reacts on events 
(SAX) instead of matching on a tree model as XSLT. This means that an 
STX processor doesn't have to store all the input data as an XSLT 
processor normally does (this could in principle be done in special 
cases for XSLT also, but it has been discussed on the Xalan-dev list and 
it seem to be very complicated to do in pracice ). Sylvain and Vadim 
seemed entusiastic about STX some while ago

There is a Java implementation of STX called Joost that implements the TrAX interfaces. To 
use it you just need joost.jar and log4j.jar (Joost has excplicit 
references to log4j everywhere in the code :( ). And as it implements 
TrAX the TraxTRansformer can be used as is, just put something like:

<map:transformer name="stx" pool-grow="2" pool-max="32" pool-min="8" 


in the component section in the sitemap and then you can use it in the 
pipelines, e.g.

<map:match pattern="*.html">
   <map:generate src="{1}.xml"/>
   <map:transform type="stx" src="{1}.stx"/>

I have just tried it at some small examples this far and have not done 
any benchmarking, but if it is stable enough it should be very usefull 
for handling e.g. large data sets from databases, something that can 
consume large amounts of memory while processed in Xalan.

/Daniel Fagerstrom

To unsubscribe, e-mail:
For additional commands, email:

View raw message