"ThreadBB" #11 prio=5 os_prio=0 tid=0x00007f613c20e000 nid=0x78e2 waiting for monitor entry [0x00007f6126944000] java.lang.Thread.State: BLOCKED (on object monitor) at demo.DeadLock.run(DeadLock.java:22) - waiting to lock <0x000000076d283280> (a java.lang.String) - locked <0x000000076d2832b8> (a java.lang.String) at java.lang.Thread.run(Thread.java:748)
"ThreadAA" #10 prio=5 os_prio=0 tid=0x00007f613c20c800 nid=0x78e1 waiting for monitor entry [0x00007f6126a45000] java.lang.Thread.State: BLOCKED (on object monitor) at demo.DeadLock.run(DeadLock.java:22) - waiting to lock <0x000000076d2832b8> (a java.lang.String) - locked <0x000000076d283280> (a java.lang.String) at java.lang.Thread.run(Thread.java:748)
"Monitor Ctrl-Break" #5 daemon prio=5 os_prio=0 tid=0x00007f613c1fe000 nid=0x78db runnable [0x00007f6127262000] java.lang.Thread.State: RUNNABLE at java.net.SocketInputStream.socketRead0(Native Method) at java.net.SocketInputStream.socketRead(SocketInputStream.java:116) at java.net.SocketInputStream.read(SocketInputStream.java:171) at java.net.SocketInputStream.read(SocketInputStream.java:141) at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) - locked <0x000000076d2fa148> (a java.io.InputStreamReader) at java.io.InputStreamReader.read(InputStreamReader.java:184) at java.io.BufferedReader.fill(BufferedReader.java:161) at java.io.BufferedReader.readLine(BufferedReader.java:324) - locked <0x000000076d2fa148> (a java.io.InputStreamReader) at java.io.BufferedReader.readLine(BufferedReader.java:389) at com.intellij.rt.execution.application.AppMainV2$1.run(AppMainV2.java:47)
"Finalizer" #3 daemon prio=8 os_prio=0 tid=0x00007f613c151000 nid=0x78c5 in Object.wait() [0x00007f61278f7000] java.lang.Thread.State: WAITING (on object monitor) at java.lang.Object.wait(Native Method) - waiting on <0x000000076d188ed8> (a java.lang.ref.ReferenceQueue$Lock) at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:144) - locked <0x000000076d188ed8> (a java.lang.ref.ReferenceQueue$Lock) at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:165) at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:216)
"Reference Handler" #2 daemon prio=10 os_prio=0 tid=0x00007f613c14c800 nid=0x78c4 in Object.wait() [0x00007f61279f8000] java.lang.Thread.State: WAITING (on object monitor) at java.lang.Object.wait(Native Method) - waiting on <0x000000076d186c00> (a java.lang.ref.Reference$Lock) at java.lang.Object.wait(Object.java:502) at java.lang.ref.Reference.tryHandlePending(Reference.java:191) - locked <0x000000076d186c00> (a java.lang.ref.Reference$Lock) at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:153)
"VM Periodic Task Thread" os_prio=0 tid=0x00007f613c20a000 nid=0x78e0 waiting on condition
JNI global references: 12
Found one Java-level deadlock: ============================= "ThreadBB": waiting to lock monitor 0x00007f6104006528 (object 0x000000076d283280, a java.lang.String), which is held by "ThreadAA" "ThreadAA": waiting to lock monitor 0x00007f6104005088 (object 0x000000076d2832b8, a java.lang.String), which is held by "ThreadBB"
Java stack information for the threads listed above: =================================================== "ThreadBB": at demo.DeadLock.run(DeadLock.java:22) - waiting to lock <0x000000076d283280> (a java.lang.String) - locked <0x000000076d2832b8> (a java.lang.String) at java.lang.Thread.run(Thread.java:748) "ThreadAA": at demo.DeadLock.run(DeadLock.java:22) - waiting to lock <0x000000076d2832b8> (a java.lang.String) - locked <0x000000076d283280> (a java.lang.String) at java.lang.Thread.run(Thread.java:748)