xml-xalan-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Cory Isaacson/CompuFlex" <cisaac...@compuflex.com>
Subject Fw: Fw: Xalan-J performance w/ compiled stylesheets
Date Sun, 18 Jun 2000 19:32:26 GMT
John,

That's my understanding, and I have gotten it to work consistently in
sub-second time.

Thanks,

Cory
----- Original Message -----
From: "John Nolt" <baghera@corp.earthlink.net>
To: <xalan-dev@xml.apache.org>
Sent: Sunday, June 18, 2000 12:21 PM
Subject: Re: Fw: Xalan-J performance w/ compiled stylesheets


> Lemme see if I'm clear: in order to improve performance when processing
multiple documents, I'll have to wrap my transformations in a Java app that
keeps the StyleSheetRoot in memory and uses it over and over.
>
> True?
>
> Thanks,
>
> John
>
> At 11:01 AM 6/18/00 -0700, you wrote:
> >John,
> >
> >Because of the serialization of the object, it gets very large and takes
a
> >long time to load. The best way to speed up Xalan (recommended by the
> >development team) is to pre-load the stylesheet into a SyleSheetRoot,
such
> >as:
> >
> >StylesheetRoot xsltDoc = xsltProcessor.processStylesheet(xsltFile);
> >
> >And then you can perform the transformation like this:
> >
> >xsltDoc.process(xmlDoc, targetDoc);
> >
> >The StylesheetRoot can be saved in memory and re-used, which is then much
> >faster.
> >
> >Thanks,
> >
> >Cory
> >
> >----- Original Message -----
> >From: "John Nolt" <baghera@corp.earthlink.net>
> >To: <xalan-dev@xml.apache.org>
> >Sent: Sunday, June 18, 2000 12:14 AM
> >Subject: Xalan-J performance w/ compiled stylesheets
> >
> >
> >> Hi,
> >>
> >> I'm using Xalan 1.0.1 with JDK 1.2.2 on a Debian Linux machine, PII
300mhz
> >with 256 megs of RAM.
> >>
> >> When I use a compiled stylesheet (supposed to improve performance),
Xalan
> >seems to take much much longer to process an XML document from source to
> >result tree. Not only is the elapsed time much longer, but it seems to
take
> >the same amount of time on the process where I compile the stylesheet
> >(using -LXCOUT and -LXCIN).
> >>
> >> Here are some result times I've gotten, using the Linux "time" function
in
> >front of the "java" command:
> >>
> >> Xalan plain jane:
> >> real    0m8.930s
> >> user    0m8.430s
> >> sys     0m0.370s
> >>
> >> The time Xalan says it took:
> >>    ========= Parsing file:/home/baghera/bar.xsl ==========
> >>    Parse of file:/home/baghera/bar.xsl took 4569 milliseconds
> >>    ========= Parsing foo.xml ==========
> >>    Parse of foo.xml took 438 milliseconds
> >>    =============================
> >>    Transforming...
> >>    transform took 342 milliseconds
> >>    XSLProcessor: done
> >>
> >>    The difference between "reported" and "real" time is 3.581 seconds.
I
> >imagine that most of the difference is overhead involved in starting the
> >Java Runtime Environment.
> >>
> >> Xalan w/ compiled XSL:
> >> real    0m15.667s
> >> user    0m12.830s
> >> sys     0m2.610s
> >>
> >> The time Xalan says it took:
> >>    ========= Parsing foo.xml ==========
> >>    Parse of foo.xml took 1090 milliseconds
> >>    =============================
> >>    Transforming...
> >>    transform took 344 milliseconds
> >>    XSLProcessor: done
> >>
> >>    The difference between "reported" and "real" time is 14.233 seconds.
> >>
> >> Notice that it doesn't report that it's parsing the xsl doc. That's
fine,
> >and would be cool if I was seeing that much of an increase in speed (4
> >seconds would be great!), but I'm not. What's it *doing* for all that
time?
> >>
> >> Thanks for any info,
> >>
> >> John Nolt
> >> Technical Editor
> >> EarthLink, Inc.
> >>
> >>
> >
> >
>


Mime
View raw message