From commons-user-return-6502-apmail-jakarta-commons-user-archive=jakarta.apache.org@jakarta.apache.org Fri Feb 06 23:14:19 2004 Return-Path: Delivered-To: apmail-jakarta-commons-user-archive@www.apache.org Received: (qmail 65270 invoked from network); 6 Feb 2004 23:14:18 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 6 Feb 2004 23:14:18 -0000 Received: (qmail 83456 invoked by uid 500); 6 Feb 2004 23:13:59 -0000 Delivered-To: apmail-jakarta-commons-user-archive@jakarta.apache.org Received: (qmail 83247 invoked by uid 500); 6 Feb 2004 23:13:58 -0000 Mailing-List: contact commons-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Jakarta Commons Users List" Reply-To: "Jakarta Commons Users List" Delivered-To: mailing list commons-user@jakarta.apache.org Received: (qmail 83227 invoked from network); 6 Feb 2004 23:13:57 -0000 Received: from unknown (HELO sccrmhc11.comcast.net) (204.127.202.55) by daedalus.apache.org with SMTP; 6 Feb 2004 23:13:57 -0000 Received: from plotnix2500 (pcp02137893pcs.reston01.va.comcast.net[68.48.26.233]) by comcast.net (sccrmhc11) with SMTP id <2004020623140301100t5i78e>; Fri, 6 Feb 2004 23:14:03 +0000 Message-ID: <0c1201c3ed06$ea833580$0500a8c0@plotnix2500> From: "Dmitri Plotnikov" To: "Jakarta Commons Users List" References: <20040206215453.56527.qmail@web60508.mail.yahoo.com> Subject: Re: JXPath Performance Date: Fri, 6 Feb 2004 18:14:05 -0500 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N All this is absolutely correct. I am using lower level APIs in my integration. However, that is work in progress and it is too early for me to make any promises. - Dmitri ----- Original Message ----- From: "Snehal Khanna" To: "Jakarta Commons Users List" Sent: Friday, February 06, 2004 4:54 PM Subject: Re: JXPath Performance > Thank you for this bit of input. My group had run > tests using XPathAPI and the numbers were quite bad > compared to JXPath. That is why I was curious to know > what you would gain by integrating with Xalan. I had a > hunch that CachedXPathAPI would probably what you had > in mind. > > However it seems that CachedXPathAPI is good so long > as the source document does not change. To compile > XPath expressions to use over any document, one would > need to use some other low level APIs. > > Regards > Snehal > > --- Dmitri Plotnikov wrote: > > It is a little bit like comparing apples and > > oranges: > > > > Xalan is an incredible XSLT processor. Its > > implementation of XPath is > > really, really fast (just don't use XPathAPI, use > > CachedXPathAPI instead). > > > > JXPath is a highly flexible interpreter that applies > > the XPath syntax to > > mixed data models: it is not designed to be the > > fastest on DOM structures. > > Rather, it is optimized for general object graph > > traversal. > > > > To summarize: if you need a high-performance XPath > > processor for DOM, go > > with Xalan. If you need to traverse heterogeneous > > object graphs, go with > > JXPath. 'Simple as that. > > > > I hope this helps. > > > > - Dmitri > > > > ----- Original Message ----- > > From: "Snehal Khanna" > > To: "Jakarta Commons Users List" > > ; > > > > Sent: Friday, February 06, 2004 4:24 PM > > Subject: Re: JXPath Performance > > > > > > > Hi Dmitri, > > > > > > Have you done any tests comparing the performance > > of > > > JXPath to Xalan? It is imperative in my project to > > use > > > a really fast XPath engine so, it would be good to > > > know how much gain in performance we are talking > > about > > > here - especially for the case I mentioned > > earlier. > > > > > > Regards, > > > ~Snehal > > > > > > > > > --- Dmitri Plotnikov wrote: > > > > JXPath is designed to work with heterogeneous > > > > models, including > > > > JavaBeans, Maps, Collections etc, as well as > > DOM, > > > > JDOM, etc. To > > > > accomodate all this variety, JXPath inevitable > > > > produces some overhead. > > > > For example it creates a bunch of NodePointer > > > > objects during the > > > > evaluation of an XPath. You wouldn't need such > > > > objects if you only > > > > worked with XML (DOM, JDOM). Thus, JXPath is > > slower > > > > than for instance > > > > Xalan, which manages to allocate almost zero > > > > objects. > > > > > > > > I am currently working on some behind-the-scenes > > > > integration between > > > > JXPath and Xalan. Once that's complete, JXPath > > > > performance will be > > > > similar to that of Xalan, as long as you are > > working > > > > exclusively with > > > > XML. > > > > > > > > I hope this helps. > > > > > > > > - Dmitri > > > > > > > > > > > > --- Snehal Khanna > > wrote: > > > > > We are in the process of evaluating two > > > > > implementations of XPath namely JXPath and > > > > jd.xpath > > > > > from www.aztecrider.com > > > > > > > > > > In our evaluations we have noticed that for > > XPath > > > > > expressions resulting in a node set with 100 > > > > nodes, > > > > > the performance of jd.xpath is superior to the > > > > > performance of JXPath. It looks like JXpath > > loses > > > > out > > > > > on performance while iterating through the > > > > results. > > > > > > > > > > For XPath expressions resulting in a single > > node > > > > > output, the performance is comparable if we > > use > > > > > compiled expressions. > > > > > > > > > > Has anyone else performed a similar analysis? > > Are > > > > > there any known performance issues with JXPath > > > > that > > > > > are currently being addressed? In general what > > is > > > > the > > > > > development plan for JXPath in terms of > > > > performance > > > > > improvements and enhancements? > > > > > > > > > > Regards, > > > > > Snehal > > > > > > > > > > > > > > > __________________________________ > > > > > Do you Yahoo!? > > > > > Yahoo! SiteBuilder - Free web site building > > tool. > > > > Try it! > > > > > http://webhosting.yahoo.com/ps/sb/ > > > > > > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > > > To unsubscribe, e-mail: > > > > commons-user-unsubscribe@jakarta.apache.org > > > > > For additional commands, e-mail: > > > > commons-user-help@jakarta.apache.org > > > > > > > > > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > > To unsubscribe, e-mail: > > > > commons-user-unsubscribe@jakarta.apache.org > > > > For additional commands, e-mail: > > > > commons-user-help@jakarta.apache.org > > > > > > > > > > > > > __________________________________ > > > Do you Yahoo!? > > > Yahoo! Finance: Get your refund fast by filing > > online. > > > http://taxes.yahoo.com/filing.html > > > > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: > > commons-user-unsubscribe@jakarta.apache.org > > For additional commands, e-mail: > > commons-user-help@jakarta.apache.org > > > > > __________________________________ > Do you Yahoo!? > Yahoo! Finance: Get your refund fast by filing online. > http://taxes.yahoo.com/filing.html > > --------------------------------------------------------------------- > To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org > For additional commands, e-mail: commons-user-help@jakarta.apache.org > > > --------------------------------------------------------------------- To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-user-help@jakarta.apache.org