|
[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
[Recent Entries]
[Reply To This Message]
Re: saxon in batch file for lots and lots of xml files
Subject: Re: saxon in batch file for lots and lots of xml files
From: Jiri Jirat <Jiri.Jirat@xxxxxxxxxxxx>
Date: Tue, 29 Jan 2002 12:14:13 +0100
|
Hello,
I think you will find our "saxonserver" useful.
See:
http://zvon.org/ZvonSW/saxonserver/Output/index.html
"..Saxonserver is a server, which gets data directly via TCP and
performs XSLT transformation using saxon. Saxonclient is a perl script,
which sends the filenames or URLs of XML and XSLT files, and pairs of
parameters to the server. The only purpose is to avoid starting Javawith
each transformation, which represents a constant delay about 2 - 3
seconds. Thus when you perform one thousand transformations you can save
nearly one hour of your precious time .."
We use saxonserver+saxonclient each day and the speed up is incredible.
Regards
Jirka
Michael Kay wrote:
Ouch!
Write a Java main program to control this rather than doing it with a batch
file. Then (a) you will only load all the Java classes once, and (b) you
will only need to compile the stylesheet once.
If you don't feel confident to write this Java code, another approach is to
use the (rather simple) mechanism provided on the Saxon command line to
process an entire directory. To achieve this you may have to copy all the
files you want to process into a new directory, because the operation isn't
selective. Use:
saxon -o output-dir input-dir convert.xsl
Mike Kay
-----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of
ronald heller
Sent: 29 January 2002 09:00
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: saxon in batch file for lots and lots of xml files
Hi there,
I have a large directory with rather small xml files. There
may be well
over 500 files in there.
Once a day these files are transformed with saxon 6.2.
Although this goes well, it takes a lot of time.
I have a feeling that is is not the transformation itself
that takes a lot
of time, but that the starting and closing of saxon is.
let me show you some code from the batchfiles:
1.bat:
---------------------------------------
for %%b in ("*.xml") do call 2.bat %%b CC
rem. for each xml file that is found I call 2.bat
2.bat
---------------------------------------
java com.icl.saxon.StyleSheet -o "%1-a" "%1" "convert.xsl"
rem for each file that has to be transformed saxon/java is
started and closed.
Is there a quicker/smarter way of doing this?
any help is appreciated
Regards,
Ronald
(ps I tried Instant saxon, but that gives more or less the
same results)
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
--
<name firstName="Jirka" surname="Jirat"/>
<mail> jiratj@xxxxxxxxxxxx </mail>
<support> http://www.zvon.org </support>
<zvonMailingList> http://www.zvon.org/index.php?nav_id=4
</zvonMailingList>
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list

| Current Thread |
- Re: RE:read-write same url in xslt 2 [was appendig to multiple output files], (continued)
- Trevor Nash - Mon, 28 Jan 2002 13:39:44 -0500 (EST)
- Evan Lenz - Mon, 28 Jan 2002 13:53:58 -0500 (EST)
- ronald heller - Tue, 29 Jan 2002 04:02:04 -0500 (EST)
- Michael Kay - Tue, 29 Jan 2002 05:28:22 -0500 (EST)
- Jiri Jirat - Tue, 29 Jan 2002 06:11:31 -0500 (EST) <=
- Alek Andreev - Tue, 29 Jan 2002 15:01:50 -0500 (EST)
- Michael Kay - Tue, 29 Jan 2002 18:04:15 -0500 (EST)
- Trevor Nash - Mon, 28 Jan 2002 05:44:23 -0500 (EST)
- Bryan Rasmussen - Mon, 28 Jan 2002 06:27:47 -0500 (EST)
|
|
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format
| RSS 2.0 |
|
| Atom 0.3 |
|
|