[jdom-interest] Time for SAXBuilder.build()
Freude, Stefan
Freude at bdr.de
Mon Oct 9 02:39:08 PDT 2000
I want to use JDOM in an internet application where I get external data in
XML format.
Every XML file has to parse with JDOM. Now I have noticed that the
SAXBuilder.build() method needs a lot of time.
Consider the very simple XML-file
<Book/>
In my code there are the following lines:
SAXBuilder builder = new SAXBuilder(false);
long time1 = System.currentTimeMillis();
Document doc = builder.build(uri);
long time2 = System.currentTimeMillis();
Before and after the build call I take the time. The unexpected result is a
time of about 2200 milliseconds (on a PII 450 under NT 4.0).
That´s too long for my application. If the XML-file is more complex the time
used for build is only a few milliseconds greater.
What can I do to reduce this warmup time?
Regards, Stefan
More information about the jdom-interest
mailing list