[jboss-jira] [JBoss JIRA] (WFLY-6315) session.invalidate() behaviour not conform Servlet specification in HA profile

Sammy Chu (JIRA) issues at jboss.org
Thu Apr 28 08:41:00 EDT 2016


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

Sammy Chu edited comment on WFLY-6315 at 4/28/16 8:40 AM:
----------------------------------------------------------

Please refer to my updated comment, maybe this is another issue, but I comment out the session invalidation code in JSP, it is still not working...
Seems even this issue being fixed, there should still have an issue, which is about not allowing to perform `invalidate()` operation (or maybe all operations) on other session instances store by a Servlet Filter.

We have such single-sign-out requirement:
# An authentication provider will issue a ticket to the App
# App associated the authentication ticket with the session Id
# When perform single sign out, the authentication server issued a callback request to the App with provided ticket, App lookup the corresponding session by the ticket and perform the `invalidate()` call.
Because Servlet API do not have standard API to lookup the corresponding session by session Id, so step 2 will use a hash map to store the session object.
And seems in Wildfly 10.x stream, calling `session.invalidate()` on other session object stored before will have issue...


was (Author: sammychu):
Please refer to my updated comment, maybe this is another issue, but I comment out the session invalidation code in JSP, it is still not working...
Seems even this issue being fixed, there should still have an issue, which is about not allowing to perform `invalidate()` operation (or maybe all operations) on other session instances store by a Servlet Filter.

We have such single-sign-out requirement:
# A authentication provider will issue an ticket to the App
# App associated the authentication ticket with the session Id
# When perform single sign out, the authentication server issued a callback request to the App with provided ticket, App lookup the corresponding session by the ticket and perform the `invalidate()` call.
Because Servlet API do not have standard API to lookup the corresponding session by session Id, so step 2 will use a hash map to store the session object.
And seems in Wildfly 10.x stream, calling `session.invalidate()` on other session object stored before will have issue...

> session.invalidate() behaviour not conform Servlet specification in HA profile
> ------------------------------------------------------------------------------
>
>                 Key: WFLY-6315
>                 URL: https://issues.jboss.org/browse/WFLY-6315
>             Project: WildFly
>          Issue Type: Bug
>          Components: Clustering
>    Affects Versions: 10.0.0.Final
>         Environment: Wildfly 8.2.1-Final
> JDK 1.8.0_66-b17
> Windows & Linux
>            Reporter: Sammy Chu
>            Assignee: Paul Ferraro
>            Priority: Blocker
>         Attachments: session-invalidate-noreplication.war, session-invalidate-noreplication.war, session-invalidate-replication-attribute.war, session-invalidate-replication-attribute.war, session-invalidate-replication-session.war, session-invalidate-replication-session.war
>
>
> We suspected that calling session.invalidate() on an already invalidated session with replication-granularity set to "ATTRIBUTE" will throw a NullPointerException, but from the specification it should throw an IllegalStateException instead.
> Stack trace as below:
> {noformat}
> 13:12:35,554 ERROR [io.undertow.request] (default task-32) UT005023: Exception handling request to /<our system url>: java.lang.NullPointerException
>     at org.wildfly.clustering.web.infinispan.session.fine.FineSessionFactory$1.invoke(FineSessionFactory.java:103)
>     at org.wildfly.clustering.web.infinispan.session.fine.FineSessionFactory$1.invoke(FineSessionFactory.java:100)
>     at org.jboss.as.clustering.infinispan.invoker.SimpleCacheInvoker.invoke(SimpleCacheInvoker.java:34)
>     at org.jboss.as.clustering.infinispan.invoker.RetryingCacheInvoker.invoke(RetryingCacheInvoker.java:87)
>     at org.wildfly.clustering.web.infinispan.session.fine.FineSessionFactory.remove(FineSessionFactory.java:109)
>     at org.wildfly.clustering.web.infinispan.session.fine.FineSessionFactory.remove(FineSessionFactory.java:53)
>     at org.wildfly.clustering.web.infinispan.session.InfinispanSession.invalidate(InfinispanSession.java:74)
>     at org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager$SchedulableSession.invalidate(InfinispanSessionManager.java:359)
>     at org.wildfly.clustering.web.undertow.session.DistributableSession.invalidate(DistributableSession.java:140)
>     at io.undertow.servlet.spec.HttpSessionImpl.invalidate(HttpSessionImpl.java:199) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> ... // our application code, just calling "session.invalidate()"
> {noformat}
> We also enclosed the simplified samples to reproduce this issue (session-invalidate-noreplication.war, session-invalidate-replication-attribute.war, session-invalidate-replication-session.war). In general they are the same except the replication-granularity (in jboss-web.xml => replication-granularity) settings.
> # session-invalidate-noreplication.war and session-invalidate-replication-session.war works correctly as they are throwing IllegalStateException.
> # session-invalidate-replication-attribute.war is buggy because it throw NullPointerException instead.
> For more information, please refer to https://developer.jboss.org/message/947295
> *Updated in 2016-04-27*
> Test again in Wildfly 8.2.1.Final, Wildfly 10.0.0.Final and Wildfly 10.1.0.Final-SNAPSHOT (master branch), with HA profile (2 nodes in same machine), with my updated WARs, detail as below:
> *Wildfly 8.2.1.Final*:
> * session-invalidate-noreplication.war - throwing IllegalStateException in the index.jsp (line 62), which is expected, detail stacktrace as below:
> {noformat}
> 15:42:56,424 INFO  [stdout] (default task-9) {} session.invalidate() throw IllegalStateException, but it is intended!!!
> 15:42:56,424 ERROR [stderr] (default task-9) {} java.lang.IllegalStateException: UT000021: Session already invalidated
> 15:42:56,424 ERROR [stderr] (default task-9) {} 	at io.undertow.server.session.InMemorySessionManager$SessionImpl.invalidate(InMemorySessionManager.java:415)
> 15:42:56,425 ERROR [stderr] (default task-9) {} 	at io.undertow.server.session.InMemorySessionManager$SessionImpl.invalidate(InMemorySessionManager.java:404)
> 15:42:56,425 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.spec.HttpSessionImpl.invalidate(HttpSessionImpl.java:199)
> 15:42:56,425 ERROR [stderr] (default task-9) {} 	at org.apache.jsp.index_jsp._jspService(index_jsp.java:62)
> 15:42:56,425 ERROR [stderr] (default task-9) {} 	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:69)
> 15:42:56,425 ERROR [stderr] (default task-9) {} 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
> 15:42:56,426 ERROR [stderr] (default task-9) {} 	at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:366)
> 15:42:56,426 ERROR [stderr] (default task-9) {} 	at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:326)
> 15:42:56,426 ERROR [stderr] (default task-9) {} 	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:259)
> 15:42:56,426 ERROR [stderr] (default task-9) {} 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
> 15:42:56,426 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:86)
> 15:42:56,426 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:130)
> 15:42:56,426 ERROR [stderr] (default task-9) {} 	at com.jboss.test.StoreSessionFilter.doFilter(StoreSessionFilter.java:72)
> 15:42:56,426 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
> 15:42:56,427 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
> 15:42:56,427 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:85)
> 15:42:56,427 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62)
> 15:42:56,427 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)
> 15:42:56,427 ERROR [stderr] (default task-9) {} 	at org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)
> 15:42:56,427 ERROR [stderr] (default task-9) {} 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 15:42:56,427 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:131)
> 15:42:56,427 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57)
> 15:42:56,428 ERROR [stderr] (default task-9) {} 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 15:42:56,428 ERROR [stderr] (default task-9) {} 	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46)
> 15:42:56,428 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64)
> 15:42:56,428 ERROR [stderr] (default task-9) {} 	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:58)
> 15:42:56,428 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:70)
> 15:42:56,428 ERROR [stderr] (default task-9) {} 	at io.undertow.security.handlers.SecurityInitialHandler.handleRequest(SecurityInitialHandler.java:76)
> 15:42:56,428 ERROR [stderr] (default task-9) {} 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 15:42:56,428 ERROR [stderr] (default task-9) {} 	at org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)
> 15:42:56,429 ERROR [stderr] (default task-9) {} 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 15:42:56,429 ERROR [stderr] (default task-9) {} 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 15:42:56,429 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:261)
> 15:42:56,429 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:248)
> 15:42:56,429 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:77)
> 15:42:56,429 ERROR [stderr] (default task-9) {} 	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:167)
> 15:42:56,429 ERROR [stderr] (default task-9) {} 	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:199)
> 15:42:56,429 ERROR [stderr] (default task-9) {} 	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:761)
> 15:42:56,430 ERROR [stderr] (default task-9) {} 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> 15:42:56,430 ERROR [stderr] (default task-9) {} 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> 15:42:56,430 ERROR [stderr] (default task-9) {} 	at java.lang.Thread.run(Thread.java:745)
> {noformat}
> * session-invalidate-replication-session.war - do *NOT* throw IllegalStateException when invalidating an already invalidated session, which is incorrect. My test just print:
> {noformat}
> 15:38:38,568 ERROR [stderr] (default task-4) {} Should not reach here!!! That means session.invalidate() do NOT throw IllegalStateException
> {noformat}
> * session-invalidate-replication-attribute.war - throwing NullPointerException in the index.jsp (line 62), which is incorrect. Detail stacktrace as below:
> {noformat}
> 15:38:57,894 ERROR [io.undertow.request] (default task-6) {} UT005023: Exception handling request to /session-invalidate-replication-attribute/index.jsp: org.apache.jasper.JasperException: JBWEB004038: An exception occurred processing JSP page /index.jsp at line 7
> 4: <%
> 5: 	if (request.getParameter("logout") != null) {
> 6: 		try {
> 7: 			session.invalidate();  // invalidate the invalidated session
> 8: 			System.err.println("Should not reach here!!! That means session.invalidate() do NOT throw IllegalStateException");
> 9: 		} catch (IllegalStateException e) {
> 10: 			// expected to throw IllegalStateException when invalidate a invalidated session
> Stacktrace:
> 	at org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:494) [jastow-1.0.0.Final.jar:1.0.0.Final]
> 	at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:408) [jastow-1.0.0.Final.jar:1.0.0.Final]
> 	at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:326) [jastow-1.0.0.Final.jar:1.0.0.Final]
> 	at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:259) [jastow-1.0.0.Final.jar:1.0.0.Final]
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) [jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
> 	at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:86) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:130) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at com.jboss.test.StoreSessionFilter.doFilter(StoreSessionFilter.java:72) [classes:]
> 	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:85) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:131) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:58) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:70) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.security.handlers.SecurityInitialHandler.handleRequest(SecurityInitialHandler.java:76) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:261) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:248) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:77) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:167) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:199) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:761) [undertow-core-1.1.8.Final.jar:1.1.8.Final]
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [rt.jar:1.8.0_92]
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0_92]
> 	at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_92]
> Caused by: java.lang.NullPointerException
> 	at org.wildfly.clustering.web.infinispan.session.fine.FineSessionFactory$1.invoke(FineSessionFactory.java:103)
> 	at org.wildfly.clustering.web.infinispan.session.fine.FineSessionFactory$1.invoke(FineSessionFactory.java:100)
> 	at org.jboss.as.clustering.infinispan.invoker.SimpleCacheInvoker.invoke(SimpleCacheInvoker.java:34)
> 	at org.jboss.as.clustering.infinispan.invoker.RetryingCacheInvoker.invoke(RetryingCacheInvoker.java:87)
> 	at org.wildfly.clustering.web.infinispan.session.fine.FineSessionFactory.remove(FineSessionFactory.java:109)
> 	at org.wildfly.clustering.web.infinispan.session.fine.FineSessionFactory.remove(FineSessionFactory.java:53)
> 	at org.wildfly.clustering.web.infinispan.session.InfinispanSession.invalidate(InfinispanSession.java:74)
> 	at org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager$SchedulableSession.invalidate(InfinispanSessionManager.java:359)
> 	at org.wildfly.clustering.web.undertow.session.DistributableSession.invalidate(DistributableSession.java:140)
> 	at io.undertow.servlet.spec.HttpSessionImpl.invalidate(HttpSessionImpl.java:199) [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
> 	at org.apache.jsp.index_jsp._jspService(index_jsp.java:62)
> 	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:69) [jastow-1.0.0.Final.jar:1.0.0.Final]
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) [jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
> 	at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:366) [jastow-1.0.0.Final.jar:1.0.0.Final]
> 	... 34 more
> {noformat}
> *Wildfly-10.0.0.Final:*
> * session-invalidate-noreplication.war - same as Wildfly 8 to throw IllegalStateException which is intended.
> * session-invalidate-replication-session.war - throwing IllegalStateException in the filter!!! (Yes, in the filter, NOT in the index.jsp!!!) which is incorrect. Detail as below:
> {noformat}
> 16:00:28,742 ERROR [org.infinispan.interceptors.InvocationContextInterceptor] (default task-5) {} ISPN000136: Error executing command GetKeyValueCommand, writing keys []: java.lang.IllegalStateException: Transaction DummyTransaction{xid=DummyXid{id=5}, status=3} is not in a valid state to be invoking cache operations on.
> 	at org.infinispan.interceptors.TxInterceptor.enlist(TxInterceptor.java:394)
> 	at org.infinispan.interceptors.TxInterceptor.enlistIfNeeded(TxInterceptor.java:350)
> 	at org.infinispan.interceptors.TxInterceptor.enlistReadAndInvokeNext(TxInterceptor.java:344)
> 	at org.infinispan.interceptors.TxInterceptor.visitGetKeyValueCommand(TxInterceptor.java:330)
> 	at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> 	at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> 	at org.infinispan.interceptors.base.CommandInterceptor.handleDefault(CommandInterceptor.java:113)
> 	at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:85)
> 	at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> 	at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> 	at org.infinispan.statetransfer.StateTransferInterceptor.handleTopologyAffectedCommand(StateTransferInterceptor.java:405)
> 	at org.infinispan.statetransfer.StateTransferInterceptor.handleDefault(StateTransferInterceptor.java:390)
> 	at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:85)
> 	at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> 	at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> 	at org.infinispan.interceptors.InvocationContextInterceptor.handleAll(InvocationContextInterceptor.java:107)
> 	at org.infinispan.interceptors.InvocationContextInterceptor.handleDefault(InvocationContextInterceptor.java:76)
> 	at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:85)
> 	at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> 	at org.infinispan.interceptors.InterceptorChain.invoke(InterceptorChain.java:336)
> 	at org.infinispan.cache.impl.CacheImpl.get(CacheImpl.java:411)
> 	at org.infinispan.cache.impl.CacheImpl.get(CacheImpl.java:403)
> 	at org.infinispan.cache.impl.AbstractDelegatingCache.get(AbstractDelegatingCache.java:286)
> 	at org.wildfly.clustering.server.registry.CacheRegistry.getEntry(CacheRegistry.java:128)
> 	at org.wildfly.clustering.web.infinispan.session.InfinispanRouteLocator.locate(InfinispanRouteLocator.java:58)
> 	at org.wildfly.clustering.web.undertow.session.DistributableSessionIdentifierCodec.encode(DistributableSessionIdentifierCodec.java:48)
> 	at org.wildfly.extension.undertow.session.CodecSessionConfig.clearSession(CodecSessionConfig.java:51)
> 	at io.undertow.servlet.spec.ServletContextImpl$ServletContextSessionConfig.clearSession(ServletContextImpl.java:985)
> 	at org.wildfly.clustering.web.undertow.session.DistributableSession.invalidate(DistributableSession.java:184)
> 	at io.undertow.servlet.spec.HttpSessionImpl.invalidate(HttpSessionImpl.java:199)
> 	at com.jboss.test.StoreSessionFilter.doFilter(StoreSessionFilter.java:58)
> 	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
> 	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
> 	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84)
> 	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62)
> 	at io.undertow.jsp.JspFileHandler.handleRequest(JspFileHandler.java:32)
> 	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)
> 	at org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:131)
> 	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46)
> 	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64)
> 	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60)
> 	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77)
> 	at io.undertow.security.handlers.NotificationReceiverHandler.handleRequest(NotificationReceiverHandler.java:50)
> 	at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:284)
> 	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:263)
> 	at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:81)
> 	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:174)
> 	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:202)
> 	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:793)
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> 	at java.lang.Thread.run(Thread.java:745)
> 16:00:28,743 ERROR [com.jboss.test.StoreSessionFilter] (default task-5) {} Transaction DummyTransaction{xid=DummyXid{id=5}, status=3} is not in a valid state to be invoking cache operations on.: java.lang.IllegalStateException: Transaction DummyTransaction{xid=DummyXid{id=5}, status=3} is not in a valid state to be invoking cache operations on.
> 	at org.infinispan.interceptors.TxInterceptor.enlist(TxInterceptor.java:394)
> 	at org.infinispan.interceptors.TxInterceptor.enlistIfNeeded(TxInterceptor.java:350)
> 	at org.infinispan.interceptors.TxInterceptor.enlistReadAndInvokeNext(TxInterceptor.java:344)
> 	at org.infinispan.interceptors.TxInterceptor.visitGetKeyValueCommand(TxInterceptor.java:330)
> 	at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> 	at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> 	at org.infinispan.interceptors.base.CommandInterceptor.handleDefault(CommandInterceptor.java:113)
> 	at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:85)
> 	at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> 	at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> 	at org.infinispan.statetransfer.StateTransferInterceptor.handleTopologyAffectedCommand(StateTransferInterceptor.java:405)
> 	at org.infinispan.statetransfer.StateTransferInterceptor.handleDefault(StateTransferInterceptor.java:390)
> 	at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:85)
> 	at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> 	at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:99)
> 	at org.infinispan.interceptors.InvocationContextInterceptor.handleAll(InvocationContextInterceptor.java:107)
> 	at org.infinispan.interceptors.InvocationContextInterceptor.handleDefault(InvocationContextInterceptor.java:76)
> 	at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:85)
> 	at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:40)
> 	at org.infinispan.interceptors.InterceptorChain.invoke(InterceptorChain.java:336)
> 	at org.infinispan.cache.impl.CacheImpl.get(CacheImpl.java:411)
> 	at org.infinispan.cache.impl.CacheImpl.get(CacheImpl.java:403)
> 	at org.infinispan.cache.impl.AbstractDelegatingCache.get(AbstractDelegatingCache.java:286)
> 	at org.wildfly.clustering.server.registry.CacheRegistry.getEntry(CacheRegistry.java:128)
> 	at org.wildfly.clustering.web.infinispan.session.InfinispanRouteLocator.locate(InfinispanRouteLocator.java:58)
> 	at org.wildfly.clustering.web.undertow.session.DistributableSessionIdentifierCodec.encode(DistributableSessionIdentifierCodec.java:48)
> 	at org.wildfly.extension.undertow.session.CodecSessionConfig.clearSession(CodecSessionConfig.java:51)
> 	at io.undertow.servlet.spec.ServletContextImpl$ServletContextSessionConfig.clearSession(ServletContextImpl.java:985)
> 	at org.wildfly.clustering.web.undertow.session.DistributableSession.invalidate(DistributableSession.java:184)
> 	at io.undertow.servlet.spec.HttpSessionImpl.invalidate(HttpSessionImpl.java:199)
> 	at com.jboss.test.StoreSessionFilter.doFilter(StoreSessionFilter.java:58)
> 	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
> 	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)
> 	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84)
> 	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62)
> 	at io.undertow.jsp.JspFileHandler.handleRequest(JspFileHandler.java:32)
> 	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)
> 	at org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:131)
> 	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46)
> 	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64)
> 	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60)
> 	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77)
> 	at io.undertow.security.handlers.NotificationReceiverHandler.handleRequest(NotificationReceiverHandler.java:50)
> 	at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
> 	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:284)
> 	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:263)
> 	at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:81)
> 	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:174)
> 	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:202)
> 	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:793)
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> 	at java.lang.Thread.run(Thread.java:745)
> 16:00:28,745 ERROR [stderr] (default task-5) {} Should not reach here!!! That means session.invalidate() do NOT throw IllegalStateException
> {noformat}
> * session-invalidate-replication-session.war - same behaviour as session-invalidate-replication-attribute.war as in Wildfly 10.0.0.Final, which throw exception in filter and do NOT throw exception in index.jsp, which is incorrect.
> *Wildfly 10.1.0.Final-SNAPSHOT*:
> those 3 cases behaviour identical as Wildfly 10.0.0.Final.



--
This message was sent by Atlassian JIRA
(v6.4.11#64026)


More information about the jboss-jira mailing list