allwmh / jvmtop

Automatically exported from code.google.com/p/jvmtop

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

An option to display threads in their thread groups would be awesome

GoogleCodeExporter opened this issue · comments

Enhancement.

It would be awesome to be able to organize the details view in a hierarchy / 
tree which would group threads under their parents.  htop is an example of do 
this for processes.  Personally, I have never found that of much use, but I see 
a lot of application for this type of output for JVM threads.

Pitfalls I see are that searching the thread group tree repetitively might be 
too cpu / time consuming and there is no guarantee that thread groups all have 
unique names, so things might get a bit tricky.

An interim step might be to simply display all threads rather than the top 10.

Original issue reported on code.google.com by DaveParillo on 10 Aug 2013 at 8:22

While I am begging for features, adding a column for thread priority would be 
nice.

Original comment by DaveParillo on 10 Aug 2013 at 8:25

Unfortunately, I see no possibilities of getting thread group / priority using 
the java management extensions which jvmtop uses.
That's the reason why jconsole/visualvm can't display these either.

Original comment by patric.r...@gmail.com on 14 Aug 2013 at 9:37

  • Added labels: Type-Enhancement
  • Removed labels: Type-Defect
Patric,
If the plan is to use the ThreadMXBean interface only, then I agree.
However, the Thread and ThreadGroup classes provide some more tools.


What do you think of this post?
http://nadeausoftware.com/articles/2008/04/java_tip_how_list_and_find_threads_an
d_thread_groups

Thanks,
Dave

Original comment by DaveParillo on 15 Aug 2013 at 2:34

Hi Dave,

the problem is that due to the remote nature of jvmtop and its use of the 
java.lang.management API, jvmtop has no access to the actual (remote jvm's) 
Thread and ThreadGroup instances.

I have doubts that this is possible at all, however if there's way to retrieve 
such information I'd be curious about the solution.
I'm keeping this issue open for a while.

Cheers,
-Patric

Original comment by patric.r...@gmail.com on 5 Dec 2013 at 11:38

  • Changed state: NeedInfo
Well, I'm not looking to have anyone go crazy in a futile attempt at the 
impossible.  Feel free to close at your discretion.

Original comment by DaveParillo on 8 Dec 2013 at 3:23