-
15. Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
tomlux Nov 9, 2014 2:34 AM (in response to javaee5)Hy,
you have to be in "full-ha" profile for your wildfly server-group and in your web.xml you have to add the "distributable" tag to configure session replication.
The exception is only thrown in full-ha mode with session replication enabled..
Tom
-
16. Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
pferraro Nov 10, 2014 9:12 AM (in response to tomlux)tomlux I'd like to look into this today - can you file an issue in jira and include steps to reproduce?
-
17. Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
tomlux Nov 10, 2014 9:40 AM (in response to pferraro)just created the jira:
Thanks,
Tom
-
18. Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
pferraro Nov 10, 2014 11:35 AM (in response to tomlux)Hmm - shouldn't your ConversationBean be @ConversationScoped, so that the container destroys long-running conversations on session invalidate?
-
19. Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
tomlux Nov 10, 2014 11:51 AM (in response to pferraro)Yes correct.
Updated already the jira
-
20. Re: Re: Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
pferraro Nov 10, 2014 7:41 PM (in response to tomlux)Thanks for the bug report. I've reproduced the issue locally and should have a fix for this tomorrow.
-
21. Re: Re: Re: Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
tomlux Nov 11, 2014 1:09 AM (in response to pferraro)Great to hear that the bug will be fixed :-)
Under WildFly 8.1.0.Final, we are also getting an exception for the same workflow (session invalide while a long-running conversation is open in full-ha mode):
[Server:server-two] 07:03:57,957 ERROR [org.infinispan.interceptors.InvocationContextInterceptor] (remote-thread-0) ISPN000136: Execution error: org.infinispan.util.concurrent.TimeoutException: Unable to acquire lock after [15 seconds] on key [org.wildfly.clustering.server.group.AddressableNode@cfd232f8] for requestor [GlobalTransaction:<master:server-one/web>:62:remote]! Lock held by [GlobalTransaction:<master:server-one/web>:61:remote]
[Server:server-two] at org.infinispan.util.concurrent.locks.LockManagerImpl.lock(LockManagerImpl.java:198)
Server:server-two] at org.infinispan.util.concurrent.locks.LockManagerImpl.acquireLock(LockManagerImpl.java:171)
Server:server-two] at org.infinispan.interceptors.locking.AbstractTxLockingInterceptor.lockKeyAndCheckOwnership(AbstractTxLockingInterceptor.java:169)
Server:server-two] at org.infinispan.interceptors.locking.AbstractTxLockingInterceptor.lockAndRegisterBackupLock(AbstractTxLockingInterceptor.java:98)
Server:server-two] at org.infinispan.interceptors.locking.PessimisticLockingInterceptor.visitLockControlCommand(PessimisticLockingInterceptor.java:235)
Server:server-two] at org.infinispan.commands.control.LockControlCommand.acceptVisitor(LockControlCommand.java:110)
Server:server-two] at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:98)
Should we also create a jira for this 8.1.0.Final exception?
Thanks,
Tom
-
22. Re: Re: Re: Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
javaee5 Nov 11, 2014 2:07 AM (in response to tomlux)Hi,
You could inject the conversation bean in login bean and before logout end any transient conversation scoped but you get another new exception in this case
Regards,
Hamed Hatami.
-
23. Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
pferraro Nov 11, 2014 10:35 AM (in response to tomlux)I've submitted a fix for master here: https://github.com/wildfly/wildfly/pull/6939
I will backport this fix to 8.x.
Does this lock acquisition timeout only happen with 8.1? Can you reproduce this against the lastest 8.x branch (to become 8.2)?
-
24. Re: Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
tomlux Nov 11, 2014 12:37 PM (in response to pferraro)Hy,
I just reproduced it on the latest 8.x branch.
See here the exception:
[Server:server-one] 18:32:45,481 ERROR [org.infinispan.interceptors.InvocationContextInterceptor] (default task-12) ISPN000136: Execution error: org.infinispan.util.concurrent.TimeoutException: Unable to acquire lock after [15 seconds] on key [org.wildfly.clustering.server.group.AddressableNode@80f711db] for requestor [GlobalTransaction:<master:server-one/web>:42:local]! Lock held by [GlobalTransaction:<master:server-one/web>:41:local]
[Server:server-one] at org.infinispan.util.concurrent.locks.LockManagerImpl.lock(LockManagerImpl.java:198)
[Server:server-one] at org.infinispan.util.concurrent.locks.LockManagerImpl.acquireLock(LockManagerImpl.java:171)
[Server:server-one] at org.infinispan.interceptors.locking.AbstractTxLockingInterceptor.lockKeyAndCheckOwnership(AbstractTxLockingInterceptor.java:169)
[Server:server-one] at org.infinispan.interceptors.locking.PessimisticLockingInterceptor.visitPutKeyValueCommand(PessimisticLockingInterceptor.java:107)
[Server:server-one] at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:70)
[Server:server-one] at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:98)
...
Thanks,
Tom
-
25. Re: Re: Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
tomlux Nov 11, 2014 2:50 PM (in response to tomlux)Paul,
I just checked out your git to check your fix.
Everything is working as expected :-) Thanks
We have an other problem with our full-ha config. I had the hope that your bugfix would also fix our second problem.
But it's still present (also on your git version).
Here the scenario to reproduce:
we deploy the convTest.war 2 times with names "convTest1" and "convTest2"
both deployments are working fine
But after we are redeploying the "convTest1" deployment and we will click on "doLogout" on "convTest2", we will get a "javax.servlet.ServletException: You have to start the service first!" error.
Here the stacktrace:
[Server:server-one] 20:43:05,683 ERROR [io.undertow.request] (default task-128) UT005023: Exception handling request to /convTest1/step1.jsf: javax.servlet.ServletException: You have to start the service first!
[Server:server-one] at javax.faces.webapp.FacesServlet.service(FacesServlet.java:659)
[Server:server-one] at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:85)
[Server:server-one] at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:61)
[Server:server-one] at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)
[Server:server-one] at org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)
[Server:server-one] at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
[Server:server-one] at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:131)
[Server:server-one] at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:56)
[Server:server-one] at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
[Server:server-one] at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:45)
[Server:server-one] at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:63)
[Server:server-one] at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:58)
[Server:server-one] at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:70)
[Server:server-one] at io.undertow.security.handlers.NotificationReceiverHandler.handleRequest(NotificationReceiverHandler.java:50)
[Server:server-one] at io.undertow.security.handlers.SecurityInitialHandler.handleRequest(SecurityInitialHandler.java:76)
[Server:server-one] at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
[Server:server-one] at org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)
[Server:server-one] at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
[Server:server-one] at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)
[Server:server-one] at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:261)
[Server:server-one] at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:247)
[Server:server-one] at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:76)
[Server:server-one] at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:166)
[Server:server-one] at io.undertow.server.Connectors.executeRootHandler(Connectors.java:198)
[Server:server-one] at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:766)
[Server:server-one] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
[Server:server-one] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
[Server:server-one] at java.lang.Thread.run(Thread.java:744)
[Server:server-one] Caused by: java.lang.IllegalStateException: You have to start the service first!
[Server:server-one] at org.infinispan.affinity.impl.KeyAffinityServiceImpl.getKeyForAddress(KeyAffinityServiceImpl.java:101)
[Server:server-one] at org.wildfly.clustering.web.infinispan.AffinityIdentifierFactory.createIdentifier(AffinityIdentifierFactory.java:50)
[Server:server-one] at org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager.createIdentifier(InfinispanSessionManager.java:222)
[Server:server-one] at org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager.createIdentifier(InfinispanSessionManager.java:83)
[Server:server-one] at org.wildfly.clustering.web.undertow.session.DistributableSessionManager.createSession(DistributableSessionManager.java:90)
[Server:server-one] at io.undertow.servlet.spec.ServletContextImpl.getSession(ServletContextImpl.java:703)
[Server:server-one] at io.undertow.servlet.spec.HttpServletRequestImpl.getSession(HttpServletRequestImpl.java:364)
[Server:server-one] at com.sun.faces.context.SessionMap.getSession(SessionMap.java:237)
[Server:server-one] at com.sun.faces.context.AlwaysPuttingSessionMap.put(AlwaysPuttingSessionMap.java:55)
[Server:server-one] at com.sun.faces.context.AlwaysPuttingSessionMap.put(AlwaysPuttingSessionMap.java:47)
[Server:server-one] at com.sun.faces.context.flash.SessionHelper.update(SessionHelper.java:73)
[Server:server-one] at com.sun.faces.context.flash.ELFlash.getFlash(ELFlash.java:321)
[Server:server-one] at com.sun.faces.context.flash.FlashFactoryImpl.getFlash(FlashFactoryImpl.java:56)
[Server:server-one] at com.sun.faces.context.ExternalContextImpl.getFlash(ExternalContextImpl.java:1107)
[Server:server-one] at com.sun.faces.lifecycle.Phase.handleBeforePhase(Phase.java:214)
[Server:server-one] at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:99)
[Server:server-one] at com.sun.faces.lifecycle.RestoreViewPhase.doPhase(RestoreViewPhase.java:121)
[Server:server-one] at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:198)
[Server:server-one] at javax.faces.webapp.FacesServlet.service(FacesServlet.java:646)
[Server:server-one] ... 27 more
Should I create a new jira for this problem?
Thanks,
Tom
-
26. Re: Re: Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
pferraro Nov 11, 2014 3:22 PM (in response to tomlux)Have you made any changes to the default infinispan subsystem configuration?
-
27. Re: Re: Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
tomlux Nov 11, 2014 3:51 PM (in response to pferraro)No, just using the default configuration "full-ha" configuration.
-
28. Re: Re: Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
pferraro Nov 11, 2014 6:13 PM (in response to tomlux)This last exception is due to an unfortunate bug in Infinispan: [ISPN-4969] Stopping a cache will stop all KeyAffinityServices created for other caches in the cache manager - JBoss Iss…
I've submitted a fix upstream here:
And have submitted a subsequent workaround commit to WildFly here:
and here (for 8.x):
[8.x] Add workaround for ISPN-4969 by pferraro · Pull Request #6940 · wildfly/wildfly · GitHub
-
29. Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'
tomlux Nov 12, 2014 1:16 AM (in response to pferraro)Paul,
I just tried out your wildfly git version with your infinispan version (7.0.1-SNAPSHOT).
Everything is working now under WildFly9.
So, it's only the 8.x branch remaining where we are getting this exception (Re: Re: working under wildfly#1334, failing under wildfly8.1, wildfly#1439, ...: throwing a DummyTransaction-javax.servlet.ServletException while 'invalidateSession'):
[Server:server-one] 18:32:45,481 ERROR [org.infinispan.interceptors.InvocationContextInterceptor] (default task-12) ISPN000136: Execution error: org.infinispan.util.concurrent.TimeoutException: Unable to acquire lock after [15 seconds] on key [org.wildfly.clustering.server.group.AddressableNode@80f711db] for requestor [GlobalTransaction:<master:server-one/web>:42:local]! Lock held by [GlobalTransaction:<master:server-one/web>:41:local]
[Server:server-one] at org.infinispan.util.concurrent.locks.LockManagerImpl.lock(LockManagerImpl.java:198)
[Server:server-one] at org.infinispan.util.concurrent.locks.LockManagerImpl.acquireLock(LockManagerImpl.java:171)
[Server:server-one] at org.infinispan.interceptors.locking.AbstractTxLockingInterceptor.lockKeyAndCheckOwnership(AbstractTxLockingInterceptor.java:169)
[Server:server-one] at org.infinispan.interceptors.locking.PessimisticLockingInterceptor.visitPutKeyValueCommand(PessimisticLockingInterceptor.java:107)
[Server:server-one] at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:70)
[Server:server-one] at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:98)
...
Thanks for all your help and your quick fixes,
Tom