struts-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Antonio Petrelli (JIRA)" <j...@apache.org>
Subject [jira] Resolved: (SB-48) Definitions that contain other definitions declared using JSP tags don't work
Date Mon, 02 Oct 2006 11:48:15 GMT
     [ http://issues.apache.org/struts/browse/SB-48?page=all ]

Antonio Petrelli resolved SB-48.
--------------------------------

    Fix Version/s: 2.0
       Resolution: Fixed

I corrected InsertTag class that now preprocesses (using a new "preprocessAttribute" method)
every attribute before processing (i.e. displaying) it.
There is an issue (I will open a JIRA issue for that) regarding  a (small) performance problem,
because the "preprocessAttribute" is called even if  the attribute does not need to be preprocessed
(like in Tiles definitions configured via tiles-defs.xml).
I also moved previously not-working tests in the currently-working set, and added some more
tests to check if inclusion of configured definitions inside not-configured ones works.

> Definitions that contain other definitions declared using JSP tags don't work
> -----------------------------------------------------------------------------
>
>                 Key: SB-48
>                 URL: http://issues.apache.org/struts/browse/SB-48
>             Project: Sandbox
>          Issue Type: Bug
>          Components: Tiles
>    Affects Versions: 2.0
>         Environment: JDK 1.5.0, Tomcat 5.5.17
>            Reporter: Antonio Petrelli
>         Assigned To: Antonio Petrelli
>             Fix For: 2.0
>
>
> Declaring a definition that contain another definition by using only JSP tags lead to
incorrect result, as shown by the following JSP pages included in test webapp:
> testinsertdefinition_composite_tags.jsp
> testinsertdefinition_composite_tags_notype.jsp
> Everything works using definitions defined in tiles-defs.xml.
> The first one also raises an exception, the stack trace is the following:
> java.lang.ClassCastException: java.lang.String
> 	at org.apache.tiles.taglib.InsertTag.processTypedAttribute(InsertTag.java:624)
> 	at org.apache.tiles.taglib.InsertTag.processName(InsertTag.java:450)
> 	at org.apache.tiles.taglib.InsertTag.createTagHandler(InsertTag.java:418)
> 	at org.apache.tiles.taglib.InsertTag.doStartTag(InsertTag.java:358)
> 	at org.apache.jsp.layout_jsp._jspx_meth_tiles_insert_1(layout_jsp.java:134)
> 	at org.apache.jsp.layout_jsp._jspService(layout_jsp.java:72)
> 	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> 	at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
> 	at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
> 	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
> 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> 	at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672)
> 	at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:574)
> 	at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:499)
> 	at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:966)
> 	at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:614)
> 	at org.apache.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java:131)
> 	at org.apache.tiles.TilesUtil.doInclude(TilesUtil.java:136)
> 	at org.apache.tiles.taglib.InsertTag.doInclude(InsertTag.java:642)
> 	at org.apache.tiles.taglib.InsertTag$InsertHandler.doEndTag(InsertTag.java:772)
> 	at org.apache.tiles.taglib.InsertTag.doEndTag(InsertTag.java:382)
> 	at org.apache.jsp.testinsertdefinition_005fcomposite_005ftags_jsp._jspx_meth_tiles_insert_0(testinsertdefinition_005fcomposite_005ftags_jsp.java:293)
> 	at org.apache.jsp.testinsertdefinition_005fcomposite_005ftags_jsp._jspService(testinsertdefinition_005fcomposite_005ftags_jsp.java:71)
> 	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> 	at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
> 	at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
> 	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
> 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> 	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
> 	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
> 	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
> 	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
> 	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
> 	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
> 	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
> 	at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
> 	at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
> 	at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
> 	at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
> 	at java.lang.Thread.run(Thread.java:595)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/struts/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message