[seam-issues] [JBoss JIRA] (JBSEAM-5067) ConcurrentModificationException in ServerConversationContext.flush()

Marek Schmidt (JIRA) jira-events at lists.jboss.org
Fri Jan 18 04:52:21 EST 2013


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

Marek Schmidt commented on JBSEAM-5067:
---------------------------------------

Well, I see two possible ways how to fix this:

1. convince Mojarra not to call .equals on SessionMap.put (good luck with that)
2. change the org.jboss.seam.intercept.JavaBeanInterceptor to skip injection and stuff on the .equals calls and assume no one need to modify contexts during .equals calls (which I consider quite reasonable)
                
> ConcurrentModificationException in ServerConversationContext.flush()
> --------------------------------------------------------------------
>
>                 Key: JBSEAM-5067
>                 URL: https://issues.jboss.org/browse/JBSEAM-5067
>             Project: Seam 2
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.3.0.Final
>         Environment: JBoss AS 7.1.0.Final (JSF RI 2.1.5)
>            Reporter: Andrey Zhemoytuk
>            Assignee: Marek Novotny
>             Fix For: 2.3.1.CR1
>
>
> The exception fails after render response phase if long running conversation is active and a bean in conversation scope (additions map) has page/conversation/session scoped outjection.
> Latest 2.3.1.CR1-SNAPSHOT (with JBSEAM-5045 fix): The same exception fails in ExceptionFilter after unhandled exception when there is active long running conversation and a component in conversation scope with a page scoped injection.
> The issue is not reproducible if http://java.net/jira/browse/JAVASERVERFACES-1685 is reverted. Call to equals in com.sun.faces.context.SessionMap#put (lines 132-138) introduced with 1685 fix causes injection/outjection to occur:
>         boolean doSet = true;
>         if (null != value && null != result) {
>             doSet = ! result.equals(value);
>         }
>         if (doSet) {
>             session.setAttribute(key, value);
>         }
> Stacktrace:
> 2013-01-09 05:09:26,576 WARN  [org.jboss.seam.jsf.SeamPhaseListener] (http--0.0.0.0-8543-1) uncaught exception, passing to exception handler: java.util.ConcurrentModificationException
> 	at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793) [rt.jar:1.6.0_30]
> 	at java.util.HashMap$EntryIterator.next(HashMap.java:834) [rt.jar:1.6.0_30]
> 	at java.util.HashMap$EntryIterator.next(HashMap.java:832) [rt.jar:1.6.0_30]
> 	at org.jboss.seam.contexts.ServerConversationContext.flush(ServerConversationContext.java:302) [jboss-seam.jar:2.3.0.Final]
> 	at org.jboss.seam.contexts.Contexts.flushAndDestroyContexts(Contexts.java:410) [jboss-seam.jar:2.3.0.Final]
> 	at org.jboss.seam.contexts.FacesLifecycle.endRequest(FacesLifecycle.java:129) [jboss-seam.jar:2.3.0.Final]
> 	at org.jboss.seam.jsf.SeamPhaseListener.afterRenderResponse(SeamPhaseListener.java:518) [jboss-seam.jar:2.3.0.Final]
> 	at org.jboss.seam.jsf.SeamPhaseListener.afterServletPhase(SeamPhaseListener.java:248) [jboss-seam.jar:2.3.0.Final]
> 	at org.jboss.seam.jsf.SeamPhaseListener.afterPhase(SeamPhaseListener.java:195) [jboss-seam.jar:2.3.0.Final]
> 	at com.sun.faces.lifecycle.Phase.handleAfterPhase(Phase.java:189) [jsf-impl-2.1.5-jbossorg-1.jar:2.1.5-SNAPSHOT]
> 	at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:107) [jsf-impl-2.1.5-jbossorg-1.jar:2.1.5-SNAPSHOT]
> 	at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139) [jsf-impl-2.1.5-jbossorg-1.jar:2.1.5-SNAPSHOT]
> 	at javax.faces.webapp.FacesServlet.service(FacesServlet.java:594) [jboss-jsf-api_2.1_spec-2.0.0.Final.jar:2.0.0.Final]

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the seam-issues mailing list