WFLYCLWEBUT0002 occurs for cross context request when sub-deployments use session sharing
Issue
- We've configured our applications for session sharing per Session sharing between the subdeployments of an EAR in EAP 7. In a request when a session is created, we see the following exception:
ERROR [io.undertow.request] (ajp task-1) UT005023: Exception handling request to /: org.apache.jasper.JasperException: javax.servlet.ServletException: javax.servlet.jsp.JspException: java.lang.RuntimeException: org.apache.jasper.JasperException: javax.servlet.ServletException: java.lang.IllegalStateException: WFLYCLWEBUT0002: Session 57_Q1ZxooUX07ReWe1L0DCrmOOW89I6NhDmPKlJZ already exists
at org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:581) [jastow-2.0.7.Final-redhat-00001.jar:2.0.7.Final-redhat-00001]
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:456) [jastow-2.0.7.Final-redhat-00001.jar:2.0.7.Final-redhat-00001]
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:403) [jastow-2.0.7.Final-redhat-00001.jar:2.0.7.Final-redhat-00001]
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:347) [jastow-2.0.7.Final-redhat-00001.jar:2.0.7.Final-redhat-00001]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:791) [jboss-servlet-api_4.0_spec-1.0.0.Final-redhat-1.jar:1.0.0.Final-redhat-1]
at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:74) [undertow-servlet-2.0.26.SP3-redhat-00001.jar:2.0.26.SP3-redhat-00001]
at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:129) [undertow-servlet-2.0.26.SP3-redhat-00001.jar:2.0.26.SP3-redhat-00001]
...
Caused by: java.lang.IllegalStateException: WFLYCLWEBUT0002: Session 57_Q1ZxooUX07ReWe1L0DCrmOOW89I6NhDmPKlJZ already exists
at org.wildfly.clustering.web.undertow.session.DistributableSessionManager.createSession(DistributableSessionManager.java:113)
at io.undertow.servlet.spec.ServletContextImpl.getSession(ServletContextImpl.java:923) [undertow-servlet-2.0.26.SP3-redhat-00001.jar:2.0.26.SP3-redhat-00001]
at io.undertow.servlet.spec.HttpServletRequestImpl.getSession(HttpServletRequestImpl.java:418) [undertow-servlet-2.0.26.SP3-redhat-00001.jar:2.0.26.SP3-redhat-00001]
at io.undertow.servlet.spec.HttpServletRequestImpl.getSession(HttpServletRequestImpl.java:423) [undertow-servlet-2.0.26.SP3-redhat-00001.jar:2.0.26.SP3-redhat-00001]
at org.apache.jasper.runtime.PageContextImpl.initialize(PageContextImpl.java:137) [jastow-2.0.7.Final-redhat-00001.jar:2.0.7.Final-redhat-00001]
at org.apache.jasper.runtime.JspFactoryImpl.internalGetPageContext(JspFactoryImpl.java:109) [jastow-2.0.7.Final-redhat-00001.jar:2.0.7.Final-redhat-00001]
at org.apache.jasper.runtime.JspFactoryImpl.getPageContext(JspFactoryImpl.java:60) [jastow-2.0.7.Final-redhat-00001.jar:2.0.7.Final-redhat-00001]
Environment
- JBoss Enterprise Application Platform (EAP) 7.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.