]
Aaron Ogburn commented on WFLY-10923:
-------------------------------------
Good point; thanks for that fix, [~pferraro]!
Also confirmed the undertow exception handling concern; will track that separately with
UNDERTOW-1402.
Server stop blocked by DistributableSessionManager after invalidation
during async request
------------------------------------------------------------------------------------------
Key: WFLY-10923
URL:
https://issues.jboss.org/browse/WFLY-10923
Project: WildFly
Issue Type: Bug
Components: Clustering
Affects Versions: 14.0.0.Beta2
Reporter: Aaron Ogburn
Assignee: Paul Ferraro
Attachments: servlet-async.war
After WFLY-10621, a DistributableSessionManager.stop hang can still occur in the
following scenario.
1. async request a starts
2. sync request b invalidates session
3. async request a completes
Upon completion, the async request does not unlock and throws following exception:
{code}
16:04:58,260 ERROR [stderr] (default task-18) Exception in thread "default
task-18" java.lang.RuntimeException: java.lang.IllegalStateException:
WFLYCLWEBUT0001: Session 8adSKXK1li8Qo15QnaIGrd31DrB6B83jEL4blzq1 is invalid
16:04:58,260 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.ServletContextImpl.invokeRunnable(ServletContextImpl.java:944)
16:04:58,260 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.AsyncContextImpl.onAsyncComplete(AsyncContextImpl.java:594)
16:04:58,260 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.AsyncContextImpl.access$100(AsyncContextImpl.java:71)
16:04:58,261 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.AsyncContextImpl$3.run(AsyncContextImpl.java:315)
16:04:58,261 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.AsyncContextImpl$6.run(AsyncContextImpl.java:473)
16:04:58,261 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.AsyncContextImpl$TaskDispatchRunnable.run(AsyncContextImpl.java:584)
16:04:58,261 ERROR [stderr] (default task-18) at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
16:04:58,261 ERROR [stderr] (default task-18) at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
16:04:58,261 ERROR [stderr] (default task-18) at java.lang.Thread.run(Thread.java:748)
16:04:58,261 ERROR [stderr] (default task-18) Caused by: java.lang.IllegalStateException:
WFLYCLWEBUT0001: Session 8adSKXK1li8Qo15QnaIGrd31DrB6B83jEL4blzq1 is invalid
16:04:58,261 ERROR [stderr] (default task-18) at
org.wildfly.clustering.web.undertow.session.DistributableSession.validate(DistributableSession.java:57)
16:04:58,261 ERROR [stderr] (default task-18) at
org.wildfly.clustering.web.undertow.session.DistributableSession.getAttribute(DistributableSession.java:157)
16:04:58,261 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.HttpSessionImpl.getAttribute(HttpSessionImpl.java:122)
16:04:58,261 ERROR [stderr] (default task-18) at
org.jboss.weld.context.http.HttpSessionContextImpl.checkBeanIdentifierIndexConsistency(HttpSessionContextImpl.java:98)
16:04:58,261 ERROR [stderr] (default task-18) at
org.jboss.weld.context.http.HttpSessionContextImpl.associate(HttpSessionContextImpl.java:47)
16:04:58,261 ERROR [stderr] (default task-18) at
org.jboss.weld.context.http.HttpSessionContextImpl.associate(HttpSessionContextImpl.java:23)
16:04:58,261 ERROR [stderr] (default task-18) at
org.jboss.weld.servlet.HttpContextLifecycle.requestInitialized(HttpContextLifecycle.java:237)
16:04:58,261 ERROR [stderr] (default task-18) at
org.jboss.weld.servlet.WeldInitialListener.requestInitialized(WeldInitialListener.java:152)
16:04:58,261 ERROR [stderr] (default task-18) at
io.undertow.servlet.core.ApplicationListeners.requestInitialized(ApplicationListeners.java:246)
16:04:58,261 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.AsyncContextImpl.setupRequestContext(AsyncContextImpl.java:678)
16:04:58,261 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.AsyncContextImpl.access$700(AsyncContextImpl.java:71)
16:04:58,261 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.AsyncContextImpl$7.run(AsyncContextImpl.java:599)
16:04:58,261 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.ServletContextImpl$2.call(ServletContextImpl.java:177)
16:04:58,262 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.ServletContextImpl$2.call(ServletContextImpl.java:174)
16:04:58,262 ERROR [stderr] (default task-18) at
io.undertow.servlet.spec.ServletContextImpl.invokeRunnable(ServletContextImpl.java:942)
16:04:58,262 ERROR [stderr] (default task-18) ... 8 more
{code}