[jdom-interest] XPATH engine

Steve Condas scondas at yahoo.com
Wed Nov 9 14:04:19 PST 2005

I am on a business trip and don't have access to the source code or application right now, so I can't get you my performance numbers, but I did something similar and my recollection was that Jaxen was pretty darn fast.  In my case we had 10s of XPath expressions and the time was dominated by parsing.  I am curious about the following questions:
1)  How many elements are there in the documents you are testing?
2)  What is an example XPath that you are evaluating?  My XPaths were very simple.
3)  How much time does it take for you to build your JDOM document?
4)  How much time does in take for you to select a single node via a typical XPath _expression?
When I was examining this problem I also looked at yfilter:  http://yfilter.cs.berkeley.edu/ ,
but found that JDOM/Jaxen was faster for my situation.

Kevin L Cobb <kevin.cobb at emergint.com> wrote:I am trying to tune some processing that uses JDOM to apply about 1000 XPATH expressions to a batch of XML files. I am using Xerces as my SAX parser implementation and thought about replacing this with something more speedy. But, the bulk of the work is really in applying these XPATH expressions, not in actually parsing the XML. I am caching the expressions as XPath objects and also only parsing the source XML into a Document object once. 
I'm wondering if JDOM allows me to replace the XPATH implementation with other implementations - I think that the default is JAXEN. Are there speedier XPATH implementations available?
Any advice on increasing the speed here would be well received. Thanks in advance.
To control your jdom-interest membership:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.jdom.org/pipermail/jdom-interest/attachments/20051109/ff704b32/attachment.htm

More information about the jdom-interest mailing list