[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: "Heap" of trouble handling input file of 500 MByte

Subject: Re: "Heap" of trouble handling input file of 500 MByte
From: Andrew Welch <andrew.j.welch@xxxxxxxxx>
Date: Tue, 22 Feb 2011 09:49:05 +0000
Re:  "Heap" of trouble handling input file of 500 MByte
On 21 February 2011 21:24,  <thehulk@xxxxxxxxxxx> wrote:
> Thanks for all these suggestions. I tried to use Saxon but ran into typical problems.

What are the typical problems?

> I have not found an endorsed dir anywhere, and after looking at about a dozen webpages, I am ready to give up and ask: how to put it > into the endorsed dir?

Drop the saxon jar into [java-home]/lib/endorsed, the endorsed
mechanism is the standard way to override classes in the jdk,
specifically TransformerFactory in this case.

> Also very usable: how to make this one program use the Saxon classes?

That was the alternative approach (which is what I do all the time
anyway), instead of:

TransformerFactory tFactory = TransformerFactory.newInstance();


TransformerFactory tFactory = new net.sf.saxon.TransformerFactoryImpl();

The former will return whichever TransformerFactory impl it finds
first on the classpath, which is Xalan by default, but will be Saxon
if the Saxon jar is in the endorsed directory.

The latter will always use Saxon.

For what its worth, you'll often hear Mike say use the separate
version of Xerces rather than the one bundled with Java, and you can
do that in a similar way - either drop it into the endorsed dir, or
explicitly create it with:

XMLReaderFactory xmlReader =

or just create the SAXParser directly.

Andrew Welch

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.