Hi All,
We are having a major issue with one of our applications, which has been built using Vaadin 7.1.5 running on WAS 8.5.
we have hit a deadlock where one of the holders has Introscope objects and the other is in the vaadin framework. Intriguingly, we have now discovered work through the load balancer to a server with Introscope (APM 9) can lead to deadlocks whereas those going directly on to the server does not although there are timeouts and long responses.
Java Stack:
at sun/misc/Unsafe.park(Native Method)
at java/util/concurrent/locks/LockSupport.park(LockSupport.java:186(Compiled Code))
at java/util/concurrent/locks/AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:834(Compiled Code))
at java/util/concurrent/locks/AbstractQueuedSynchronizer.acquireQueued(AbstractQueuedSynchronizer.java:867(Compiled Code))
at java/util/concurrent/locks/AbstractQueuedSynchronizer.acquire(AbstractQueuedSynchronizer.java:1197(Compiled Code))
at java/util/concurrent/locks/ReentrantLock$NonfairSync.lock(ReentrantLock.java:214(Compiled Code))
at java/util/concurrent/locks/ReentrantLock.lock(ReentrantLock.java:290(Compiled Code))
at com/vaadin/server/VaadinSession.lock(VaadinSession.java:890(Compiled Code))
at com/vaadin/server/VaadinSession.accessSynchronously(VaadinSession.java:1213)
at com/vaadin/server/VaadinService.fireSessionDestroy(VaadinService.java:437)
at com/vaadin/server/VaadinSession.valueUnbound(VaadinSession.java:261)
at com/ibm/ws/session/http/HttpSessionObserver.sessionDestroyed(HttpSessionObserver.java:193)
at com/ibm/ws/session/SessionEventDispatcher.sessionDestroyed(SessionEventDispatcher.java:160)
at com/ibm/ws/session/StoreCallback.sessionInvalidated(StoreCallback.java:126)
at com/ibm/ws/session/store/memory/MemorySession.invalidate(MemorySession.java:232)
at com/ibm/ws/session/http/HttpSessionImpl.invalidate(HttpSessionImpl.java:303)
at com/ibm/ws/session/SessionData.invalidate(SessionData.java:247)
at com/ibm/ws/session/SessionContext.doSecurityCheck(SessionContext.java:567)
at com/ibm/ws/session/SessionContext.getIHttpSession(SessionContext.java:507)
at com/ibm/ws/session/SessionContext.getIHttpSession(SessionContext.java:426(Compiled Code))
at com/ibm/ws/webcontainer/srt/SRTRequestContext.getSession(SRTRequestContext.java:104(Compiled Code))
at com/ibm/ws/webcontainer/srt/SRTServletRequest.getSession(SRTServletRequest.java:2157(Compiled Code))
at com/wily/introscope/agent/servlethelper/ServletRequestHelper.getSession(ServletRequestHelper.java:286)
at com/wily/introscope/agent/servlethelper/ServletRequestHelper.get(ServletRequestHelper.java:513)
at com/wily/introscope/agent/trace/hc2/HttpServletLazyMapProvider.get(HttpServletLazyMapProvider.java:63)
at com/wily/util/adt/LazyMap.get(LazyMap.java:182(Compiled Code))
at com/wily/introscope/agent/trace/hc2/HttpServletLazyMap.putAllParameters(HttpServletLazyMap.java:191)
at com/wily/introscope/agent/trace/hc2/HttpServletTracer.IInvocationDataParameterCallback_addParameters(HttpServletTracer.java:782)
at com/wily/introscope/agent/trace/InvocationData.addParameterCallbacks(InvocationData.java:3486)
at com/wily/introscope/agent/feature/VirtualStackFeatureHelper.fillComponentParams(VirtualStackFeatureHelper.java:157)
at com/wily/introscope/agent/feature/VirtualStackFeatureHelper.getTransanctionSnapShotFromInvocationData(VirtualStackFeatureHelper.java:235)
at com/wily/introscope/agent/feature/VirtualStackFeatureHelper.getTransactionSnapshotFromStack(VirtualStackFeatureHelper.java:75)
at com/wily/introscope/agent/feature/StallFeatureBase.reportStall(StallFeatureBase.java:50)
at com/wily/introscope/agent/feature/StallCheckBehaviorCorrect.ITimestampedRunnable_execute(StallCheckBehaviorCorrect.java:61(Compiled Code))
at com/wily/util/heartbeat/IntervalHeartbeat$BehaviorNode.execute(IntervalHeartbeat.java:972(Compiled Code))
at com/wily/util/heartbeat/IntervalHeartbeat.executeNextBehaviorAndCalculateSleepTime(IntervalHeartbeat.java:491(Compiled Code))
at com/wily/util/heartbeat/IntervalHeartbeat.access$2(IntervalHeartbeat.java:445(Compiled Code))
at com/wily/util/heartbeat/IntervalHeartbeat$HeartbeatRunnable.run(IntervalHeartbeat.java:668)
at java/lang/Thread.run(Thread.java:781)
and this is the blocked/deadlocked one:-
at com/ibm/ws/session/http/HttpSessionImpl.getAttribute(HttpSessionImpl.java:189(Compiled Code))
at com/ibm/ws/session/SessionData.getSessionValue(SessionData.java:307(Compiled Code))
at com/ibm/ws/session/SessionData.getAttribute(SessionData.java:163(Compiled Code))
at com/ibm/ws/session/HttpSessionFacade.getAttribute(HttpSessionFacade.java:139(Compiled Code))
at com/vaadin/server/WrappedHttpSession.getAttribute(WrappedHttpSession.java:54(Compiled Code))
at com/vaadin/server/VaadinService.lockSession(VaadinService.java:596)
at com/vaadin/server/VaadinService.findOrCreateVaadinSession(VaadinService.java:625)
at com/vaadin/server/VaadinService.findVaadinSession(VaadinService.java:495)
at com/vaadin/server/VaadinService.handleRequest(VaadinService.java:1365)
at com/vaadin/server/VaadinServlet.service(VaadinServlet.java:238)
at javax/servlet/http/HttpServlet.service(HttpServlet.java:668)
at com/ibm/ws/webcontainer/servlet/ServletWrapper.service(ServletWrapper.java:1230)
at com/ibm/ws/webcontainer/servlet/ServletWrapper.handleRequest(ServletWrapper.java:779)
at com/ibm/ws/webcontainer/servlet/ServletWrapper.handleRequest(ServletWrapper.java:478)
at com/ibm/ws/webcontainer/servlet/ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
at com/ibm/ws/webcontainer/filter/WebAppFilterChain.invokeTarget(WebAppFilterChain.java:136)
at com/ibm/ws/webcontainer/filter/WebAppFilterChain.doFilter(WebAppFilterChain.java:97)
at com/tnt/vcm/application/security/LoginAuthorisationFilter.doFilter(LoginAuthorisationFilter.java:142)
at com/ibm/ws/webcontainer/filter/FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:195)
at com/ibm/ws/webcontainer/filter/WebAppFilterChain.doFilter(WebAppFilterChain.java:91)
at com/ibm/ws/webcontainer/filter/WebAppFilterManager.doFilter(WebAppFilterManager.java:960)
at com/ibm/ws/webcontainer/filter/WebAppFilterManager.invokeFilters(WebAppFilterManager.java:1064)
at com/ibm/ws/webcontainer/servlet/CacheServletWrapper.handleRequest(CacheServletWrapper.java:87)
at com/ibm/ws/webcontainer/WebContainer.handleRequest(WebContainer.java:909)
at com/ibm/ws/webcontainer/WSWebContainer.handleRequest(WSWebContainer.java:1662)
at com/ibm/ws/webcontainer/channel/WCChannelLink.ready(WCChannelLink.java:200)
at com/ibm/ws/http/channel/inbound/impl/HttpInboundLink.handleDiscrimination(HttpInboundLink.java:459)
at com/ibm/ws/http/channel/inbound/impl/HttpInboundLink.handleNewRequest(HttpInboundLink.java:526)
at com/ibm/ws/http/channel/inbound/impl/HttpInboundLink.processRequest(HttpInboundLink.java:312)
at com/ibm/ws/http/channel/inbound/impl/HttpInboundLink.ready(HttpInboundLink.java:283)
at com/ibm/ws/tcp/channel/impl/NewConnectionInitialReadCallback.sendToDiscriminators(NewConnectionInitialReadCallback.java:214)
at com/ibm/ws/tcp/channel/impl/NewConnectionInitialReadCallback.complete(NewConnectionInitialReadCallback.java:113)
at com/ibm/ws/tcp/channel/impl/AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:175)
at com/ibm/io/async/AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com/ibm/io/async/AsyncChannelFuture$1.run(AsyncChannelFuture.java:205)
at com/ibm/ws/util/ThreadPool$Worker.run(ThreadPool.java:1862(Compiled Code))
So, basically we need to know what the root cause of the deadlock and thread hang ? Anyone came across similar issue and can advise please ?
Thanks