Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I interpret at Java thread that is RUNNABLE but with no stack trace?

Tags:

java

debugging

I am debugging a legacy Java application, and the thread dump (obtained via jstack) contains some entries like the following:

"Thread-8" prio=10 tid=0x0000000055f2c800 nid=0x49bf runnable [0x0000000000000000]
    java.lang.Thread.State: RUNNABLE

That's it. No stack trace.

What's going on here? How do I locate the Java code executing in this thread?

like image 838
noahlz Avatar asked Jan 11 '13 20:01

noahlz


People also ask

How do you analyze thread dump?

To find the long running threads, highlight all the thread dumps you want to check, and then click on the binoculars: In the pop up dialogue, click start detection, and you'll get your long running threads just below the dumps themselves: In my example, each thread dump has 157 threads.

What does locked Ownable synchronizers mean?

At the same time, we can find these handles in the locked ownable synchronizers of their respective threads. Basically, this means that we can see which locks our threads are waiting for and which thread owns those locks. This helps us troubleshoot concurrency issues including deadlocks.


1 Answers

The thread isn't (or wasn't) executing Java code. It's handling tasks not implemented in Java that weren't directly requested by any Java caller. For example, if the corresponding OS thread just caught a signal.

like image 100
David Schwartz Avatar answered Oct 20 '22 20:10

David Schwartz