[weld-issues] [JBoss JIRA] (WELD-1068) Weld conversation crash when used in portlet

Marko Strukelj (JIRA) jira-events at lists.jboss.org
Mon Feb 27 09:28:38 EST 2012


    [ https://issues.jboss.org/browse/WELD-1068?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12671196#comment-12671196 ] 

Marko Strukelj commented on WELD-1068:
--------------------------------------

It looks like cross context include issue. 

See:
 - https://github.com/weld/core/pull/140
 - https://github.com/mstruk/core/commit/79b2f6e0d1bfbdbadfba71acaff9eb332be7bfae#diff-0

RequestInitialized and RequestDestroyed events are not received when crossing the context. They have to be simulated through a framework specific mechanism.

It would be nice if Servlet spec had some kind of option to turn on replaying these events to crossed-over contexts on a per-app basis.

Maybe something to suggest for the next version of Servlet Spec.


                
> Weld conversation crash when used in portlet
> --------------------------------------------
>
>                 Key: WELD-1068
>                 URL: https://issues.jboss.org/browse/WELD-1068
>             Project: Weld
>          Issue Type: Bug
>          Components: Conversations
>    Affects Versions: 1.1.5.Final
>         Environment: Windows XP, Tomcat 7.0.23, Liferay 6.1.0 Community Edition GA1, Mojarra 2.1.6, portletfaces-bridge 2.0.0
>            Reporter: John Doyle
>            Assignee: Marko Strukelj
>         Attachments: portlet-test.war, test1.zip
>
>
> When attempting to view a JSF2/Weld based portlet in a portal the following exception is thrown:
> 14:11:54,917 ERROR [render_portlet_jsp:154] java.lang.IllegalStateException: Must call associate() before calling activate()
>         at org.jboss.weld.context.AbstractConversationContext.activate(AbstractConversationContext.java:200)
>         at org.jboss.weld.jsf.WeldPhaseListener.activateConversations(WeldPhaseListener.java:108)
>         at org.jboss.weld.jsf.WeldPhaseListener.beforePhase(WeldPhaseListener.java:85)
>         at com.sun.faces.lifecycle.Phase.handleBeforePhase(Phase.java:228)
>         at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:99)
>         at com.sun.faces.lifecycle.RestoreViewPhase.doPhase(RestoreViewPhase.java:116)
>         at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
>         at org.portletfaces.bridge.BridgeImpl.doFacesRequest(BridgeImpl.java:391)
>         at org.portletfaces.bridge.GenericFacesPortlet.doView(GenericFacesPortlet.java:181)
>         at javax.portlet.GenericPortlet.doDispatch(GenericPortlet.java:328)
>         at javax.portlet.GenericPortlet.render(GenericPortlet.java:233)
>         at com.liferay.portlet.FilterChainImpl.doFilter(FilterChainImpl.java:100)
>         at com.liferay.portal.kernel.portlet.PortletFilterUtil.doFilter(PortletFilterUtil.java:64)
>         at com.liferay.portal.kernel.servlet.PortletServlet.service(PortletServlet.java:93)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
>         at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilterChain.doFilter(InvokerFilterChain.java:72)
>         at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.doFilter(InvokerFilter.java:70)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
> This happens on viewing a page which starts a conversation. I'll try and attach a little example app to aid reproducing the problem.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the weld-issues mailing list