[jboss-jira] [JBoss JIRA] Created: (JBAS-7496) Unable to compile recursive jsp tag.
Danilo Ghirardelli (JIRA)
jira-events at lists.jboss.org
Wed Dec 2 09:12:29 EST 2009
Unable to compile recursive jsp tag.
------------------------------------
Key: JBAS-7496
URL: https://jira.jboss.org/jira/browse/JBAS-7496
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Build System, Other
Affects Versions: JBossAS-5.1.0.GA, JBossAS-4.2.3.GA
Environment: Tried both on Windows XP SP3 and latest Ubuntu.
Reporter: Danilo Ghirardelli
Assignee: Paul Gier
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/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list