[
https://jira.jboss.org/browse/JBAS-7496?page=com.atlassian.jira.plugin.sy...
]
Jason T. Greene reassigned JBAS-7496:
-------------------------------------
Assignee: Remy Maucherat (was: Jason T. Greene)
Hi Remy,
I'm not sure if you are still looking at jasper issues, or if someone else should.
Feel free to bounce it if I have the wrong person.
Unable to compile recursive jsp tag.
------------------------------------
Key: JBAS-7496
URL:
https://jira.jboss.org/browse/JBAS-7496
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Build System, Other
Affects Versions: JBossAS-4.2.3.GA, JBossAS-5.1.0.GA
Environment: Tried both on Windows XP SP3 and latest Ubuntu.
Reporter: Danilo Ghirardelli
Assignee: Remy Maucherat
Create a simple jsp tag that calls itself recursively, just like the one in the forum
post. If you try to access a jsp that calls the tag, the server will throw a classNotFound
exception for the tag class. Seems that the jsp compiler is unable to compile recursive
jsp tags.
The problem is on both 4.3 and 5.1 versions, I haven't tested other versions.
Tomcat is able to compile the same tag without problems, so the first (and ugliest)
workaround is (if the tag is simple enough) to compile it with Tomcat and move the
compiled class to JBoss.
The file is called recur.tag and is placed under /WEB-INF/tags/myTags:
<jsp:root version="2.1"
xmlns:jsp="http://java.sun.com/JSP/Page"
xmlns:c="http://java.sun.com/jsp/jstl/core"
xmlns:fmt="http://java.sun.com/jsp/jstl/fmt"
xmlns:fn="http://java.sun.com/jsp/jstl/functions"
xmlns:mytags="urn:jsptagdir:/WEB-INF/tags/myTags">
<!--
Creates an xml representation of the category tree.
-->
<!-- The category node -->
<jsp:directive.attribute name="category" type="MyObject"
required="true" rtexprvalue="true" />
<!-- Children categories should be included? -->
<jsp:directive.attribute name="includeChildren"
type="java.lang.Boolean" required="false" rtexprvalue="true"
/>
<category>
<name>${category.name}</name>
<children>
<c:if test="${includeChildren}">
<mytags:recur categoryNode="${subCategory}"
includeChildren="${includeChildren}" />
</c:if>
</children>
</category>
</jsp:root>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira