commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Csaba Győrffy <>
Subject [Jelly] XML ForEach tag hangs
Date Sat, 30 Apr 2011 01:02:09 GMT
Hello there!

I'm trying to use the ForEach tag in Jelly's XML tag library. The
following script works fine in a standard Java console application:

<x:parse var="doc">
    <b v="1"/>
    <b v="2"/>
    <b v="3"/>

<x:forEach select="$doc/a/b" var="x">

However, if using Jelly on an application server, from inside an EJB
container (session bean), running the script above hangs, and 100% CPU
utilisation comes. I realized while debugging that NodeComparator
class' getDepth method gets into an infinite loop and never returns.

If I remove two "b" elements from the xml fragment above (so only one
remains), it works fine. It also works if I change the second part of
the above script to the following:

<x:forEach select="$doc/a">
  <x:forEach select="b">

Does anyone have any idea why is that happening? Any help is much appreciated.

Thank you:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message