Yeah, both Drools SE and the EIP Xpath router could benefit such a library. Thanks a lot, Dan ! However this won't avoid parsing the xml to a DOM because we will still have to send it to the destination after the xpath routing has been performed. But I think this could still boost performances a lot. Does it support evaluating multiple xpath expression at the same time ? I.e. you give all the xpath expressions, and they are all evaluated at the same time, so that the first one matching will be fired .... Need to look at SXC a bit more ...
On 3/17/07, Grant M <[EMAIL PROTECTED]> wrote:
Were you thinking of integrating it with EIP routing? That could possibly be done. On 3/17/07, Dan Diephouse <[EMAIL PROTECTED]> wrote: > Hi All, > > I think I wrote something which may be of use to ServiceMix, but > unfortunately I don't have time to integrate it myself - so I'm going to > throw it out there for everyone :-) > > I started a project called SXC - simple xml compiler - which creates > optimized xml parsers for various things. There is one for JAXB. But, the > one of probably the most interest to this crew is the XPath frontend. SXC > can build a streaming xpath parser for you (at runtime). This means you can > listen for XPath events as you scan over the document. This allows for very > efficient XPath based routing. In my initial performance test it was about > 100x faster than Jaxen for locating nodes (although thats a very rough > benchmark, real numbers may vary!) > > We also integrated it with Drools so you can write XPath expressions right > in your rules. > > Check out these links for more information: > > http://sxc.codehaus.org > http://sxc.codehaus.org/XPath > http://sxc.codehaus.org/Drools > > The one caveat is that we support only a limited subset of XPath expressions > at the moment. But if you wanted to hack SXC, its easy enough to add more. > I'm happy to help where I can or give guidance to anyone who wants to > participate as well. > > Anyone up for hacking it into servicemix? :-) > > - Dan > > -- > Dan Diephouse > Envoi Solutions > http://envoisolutions.com | http://netzooid.com/blog >
-- Cheers, Guillaume Nodet ------------------------ Architect, LogicBlaze (http://www.logicblaze.com/) Blog: http://gnodet.blogspot.com/
