JPPF Issue Tracker
star_faded.png
Please log in to bookmark issues
bug_report_small.png
CLOSED  Bug report JPPF-382  -  Server deadlock (v4.2.7)
Posted Apr 08, 2015 - updated Apr 08, 2015
icon_info.png This issue has been closed with status "Closed" and resolution "RESOLVED".
Issue details
  • Type of issue
    Bug report
  • Status
     
    Closed
  • Assigned to
     lolo4j
  • Progress
       
  • Type of bug
    Not triaged
  • Likelihood
    Not triaged
  • Effect
    Not triaged
  • Posted by
     lolo4j
  • Owned by
    Not owned by anyone
  • Category
    Server
  • Resolution
    RESOLVED
  • Priority
    Normal
  • Reproducability
    Can't reproduce
  • Severity
    Normal
  • Targetted for
    icon_milestones.png JPPF 4.2.8
Issue description
The following deadlock was found in the 4.2.7 driver:
"jmx@10.173.26.72:36000":
  waiting to lock monitor 0x00002ab8ba5e45c8 (object 0x00000005c038d7d0, a java.util.LinkedHashSet),
  which is held by "TaskQueueChecker"
 
"TaskQueueChecker":
  waiting for ownable synchronizer 0x00000005c03db8f8, (a java.util.concurrent.locks.ReentrantLock$NonfairSync),
  which is held by "NodeJobServer-0004"
 
"NodeJobServer-0004":
  waiting to lock monitor 0x00002ab8ba5e45c8 (object 0x00000005c038d7d0, a java.util.LinkedHashSet),
  which is held by "TaskQueueChecker"
 
Java stack information for the threads listed above:
===================================================
 
"jmx@10.173.26.72:36000":
  at org.jppf.server.nio.nodeserver.TaskQueueChecker.removeIdleChannel(TaskQueueChecker.java:183)
  - waiting to lock <0x00000005c038d7d0> (a java.util.LinkedHashSet)
  at org.jppf.server.nio.nodeserver.NodeNioServer.updateConnectionStatus(NodeNioServer.java:274)
  at org.jppf.server.nio.nodeserver.NodeNioServer.addConnection(NodeNioServer.java:182)
  at org.jppf.server.nio.nodeserver.NodeNioServer.nodeConnected(NodeNioServer.java:506)
  at org.jppf.server.nio.nodeserver.AbstractNodeContext$2.jmxWrapperConnected(AbstractNodeContext.java:414)
  at org.jppf.management.JMXConnectionWrapper.fireConnected(JMXConnectionWrapper.java:523)
  at org.jppf.management.JMXConnectionWrapper.performConnection(JMXConnectionWrapper.java:227)
  at org.jppf.management.JMXConnectionThread.run(JMXConnectionThread.java:56)
  at java.lang.Thread.run(Thread.java:745)
 
"TaskQueueChecker":
  at sun.misc.Unsafe.park(Native Method)
  - parking to wait for  <0x00000005c03db8f8> (a java.util.concurrent.locks.ReentrantLock$NonfairSync)
  at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175)
  at java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:836)
  at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireQueued(AbstractQueuedSynchronizer.java:870)
  at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquire(AbstractQueuedSynchronizer.java:1199)
  at java.util.concurrent.locks.ReentrantLock$NonfairSync.lock(ReentrantLock.java:209)
  at java.util.concurrent.locks.ReentrantLock.lock(ReentrantLock.java:285)
  at org.jppf.nio.StateTransitionManager.transitionChannel(StateTransitionManager.java:137)
  at org.jppf.nio.StateTransitionManager.transitionChannel(StateTransitionManager.java:123)
  at org.jppf.server.nio.nodeserver.AbstractNodeContext.submit(AbstractNodeContext.java:465)
  at org.jppf.server.nio.nodeserver.TaskQueueChecker.dispatchJobToChannel(TaskQueueChecker.java:321)
  - locked <0x0000000790f63a18> (a org.jppf.nio.SelectionKeyWrapper)
  at org.jppf.server.nio.nodeserver.TaskQueueChecker.dispatch(TaskQueueChecker.java:256)
  - locked <0x0000000790f63a18> (a org.jppf.nio.SelectionKeyWrapper)
  - locked <0x00000005c038d7d0> (a java.util.LinkedHashSet)
  at org.jppf.server.nio.nodeserver.TaskQueueChecker.run(TaskQueueChecker.java:214)
  at java.lang.Thread.run(Thread.java:745)
 
"NodeJobServer-0004":
  at org.jppf.server.nio.nodeserver.TaskQueueChecker.removeIdleChannel(TaskQueueChecker.java:183)
  - waiting to lock <0x00000005c038d7d0> (a java.util.LinkedHashSet)
  at org.jppf.server.nio.nodeserver.NodeNioServer.updateConnectionStatus(NodeNioServer.java:274)
  at org.jppf.server.nio.nodeserver.NodeNioServer.access$000(NodeNioServer.java:48)
  at org.jppf.server.nio.nodeserver.NodeNioServer$1.executionStatusChanged(NodeNioServer.java:109)
  at org.jppf.server.nio.nodeserver.AbstractNodeContext.fireExecutionStatusChanged(AbstractNodeContext.java:500)
  at org.jppf.server.nio.nodeserver.AbstractNodeContext.setState(AbstractNodeContext.java:369)
  at org.jppf.server.nio.nodeserver.AbstractNodeContext.setState(AbstractNodeContext.java:46)
  at org.jppf.nio.StateTransitionManager.transitionChannel(StateTransitionManager.java:152)
  - locked <0x0000000791211b40> (a org.jppf.nio.SelectionKeyWrapper)
  at org.jppf.nio.StateTransitionTask.run(StateTransitionTask.java:79)
  - locked <0x0000000791211b40> (a org.jppf.nio.SelectionKeyWrapper)
  at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
  at java.util.concurrent.FutureTask.run(FutureTask.java:266)
  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)
Looking at the code in the trunk and branch 5.0, removing an idle channel is already done asynchronously, so the conditions for triggering the deadlock do not occur in these versions.
Steps to reproduce this issue
TBD

#4
Comment posted by
 lolo4j
Apr 08, 08:32
Fixed in branch b4.2 revision 3668