[ 
https://issues.apache.org/jira/browse/TOMAHAWK-596?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12559864#action_12559864
 ] 

Marko Asplund commented on TOMAHAWK-596:
----------------------------------------

I'm also seeing this problem with a portlet I'm developing with JSF using the 
Tomahawk t:dataTable action in combination with t:dataScroller for implementing 
a pageable search results page.
The page includes a form for typing in search criteria and dataTable is used 
for representing the results.
Part of the time this is working as expected but occasionally I receive error 
messages about duplicate components in the component tree (see below).
I'm using Tomahawk 1.1.3 and the application runs on WebSphere Portal Server 
6.0.
I've also tested this with Tomahawk 1.1.6 and the issue can be reproduced with 
that version as well.

Caused by: java.lang.IllegalStateException: Client-id : scrollerprevious is 
duplicated in the faces tree. Component : listForm:scrollerprevious, path: 
{Component-Path : [Class: javax.faces.component.UIViewRoot,ViewId: 
/WEB-INF/jsp/acars/listReports.jsp][Class: 
org.apache.myfaces.custom.div.Div,Id: _idJsp0PC_7_BAQQI5230OL3C02
T1C1LCM30D2_][Class: javax.faces.component.html.HtmlForm,Id: listForm][Class: 
org.apache.myfaces.custom.div.Div,Id: 
_idJsp38PC_7_BAQQI5230OL3C02T1C1LCM30D2_][Class: 
javax.faces.component.html.HtmlPanelGrid,Id: 
_idJsp80PC_7_BAQQI5230OL3C02T1C1LCM30D2_][Class: 
org.apache.myfaces.custom.datascroller.HtmlDataScroller,Id: scroller][Class: 
javax.faces.component.html.HtmlCommandLink,Id: scrollerprevious]}
       at 
org.apache.myfaces.application.jsp.JspStateManagerImpl.checkForDuplicateIds(JspStateManagerImpl.java(Compiled
 Code))
       at 
org.apache.myfaces.application.jsp.JspStateManagerImpl.checkForDuplicateIds(JspStateManagerImpl.java(Compiled
 Code))
       at 
org.apache.myfaces.application.jsp.JspStateManagerImpl.checkForDuplicateIds(JspStateManagerImpl.java(Compiled
 Code))
       at 
org.apache.myfaces.application.jsp.JspStateManagerImpl.checkForDuplicateIds(JspStateManagerImpl.java(Compiled
 Code))
       at 
org.apache.myfaces.application.jsp.JspStateManagerImpl.checkForDuplicateIds(JspStateManagerImpl.java(Compiled
 Code))
       at 
org.apache.myfaces.application.jsp.JspStateManagerImpl.checkForDuplicateIds(JspStateManagerImpl.java(Compiled
 Code))
       at 
org.apache.myfaces.application.jsp.JspStateManagerImpl.checkForDuplicateIds(JspStateManagerImpl.java(Compiled
 Code))
       at 
org.apache.myfaces.application.jsp.JspStateManagerImpl.saveSerializedView(JspStateManagerImpl.java:305)
       at org.apache.myfaces.taglib.core.ViewTag.doAfterBody(ViewTag.java:122)
       at com.ibm._jsp._listReports._jspx_meth_f_view_0(_listReports.java:1671)
       at com.ibm._jsp._listReports._jspService(_listReports.java:89)
       at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java(Compiled 
Code))
       at javax.servlet.http.HttpServlet.service(HttpServlet.java(Compiled 
Code))
       at 
com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java(Compiled
 Code))
       at 
com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java(Compiled
 Code))
       at 
com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java(Compiled
 Code))
       at 
com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java(Compiled
 Code))
       at 
com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java(Compiled
 Code))
       at 
com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java(Inlined
 Compiled Code))
       at 
com.ibm.ws.jsp.webcontainerext.JSPExtensionServletWrapper.handleRequest(JSPExtensionServletWrapper.java(Compiled
 Code))
       at 
com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.include(WebAppRequestDispatcher.java(Compiled
 Code))
       at 
org.apache.pluto.core.impl.PortletRequestDispatcherImpl.include(PortletRequestDispatcherImpl.java:112)
       ... 170 more


> Duplicate id exception for HtmlDataScrollerRenderer
> ---------------------------------------------------
>
>                 Key: TOMAHAWK-596
>                 URL: https://issues.apache.org/jira/browse/TOMAHAWK-596
>             Project: MyFaces Tomahawk
>          Issue Type: Bug
>          Components: Data Scroller
>    Affects Versions: 1.1.3
>         Environment: Linux, Windows
>            Reporter: Ryan Wynn
>         Attachments: HtmlDataScrollerRenderer.java, 
> HtmlDataScrollerRenderer.java.example, HtmlDataScrollerRenderer.patch
>
>
> In a portlet environment a non-faces request produces an exception when the 
> faces tree is rendered if the faces tree contains a DataScroller component.  
> The HtmlDataScroller renderer actually renders its children twice in this 
> case, once in the encodeChildren method and once in the encodeEnd method.  
> Since rendering of the children is taken care of in encodeEnd I made the 
> encodeChildren method a no-op.  Also, although the  CommandLinks which are 
> rendered as children are marked as transient, they see to stick around.  I 
> put a check in the getLink methods to make sure that the links are not added 
> twice.  This seems to fix the duplicate id exception, but it might be 
> necessary to further investigate why they are sticking around in the first 
> place.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to