This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
We need the "Threads" debugger tab to indicate whether a thread is daemon or not in order to figure out what threads are preventing the application from shutting down.
This will most probably not be implemented, unless appropriate method is added into JDI API. Currently there is no way, through JDI to find out whether a thread is daemon or not. Thus the only way to retrieve that information is to call Thread.isDaemon(). But methods can be called only when a thread is suspended by an event - e.g. breakpoint event.
mentlicher, I'm only expecting to see this information when threads are suspended, such as when a breakpoint is hit or a developer hits the pause button.
If you hit pause, we can not invoke any methods. The suspension has to come from a registered event - breakpoint, step, etc. That's a limitation of JDI. It seems to me that this behavior is too limiting for this feature.
I'm confused. When I click on pause, I can then go into the "watch" window and execute "Thread.currentThread().isDaemon()". Why can't Netbeans do the same automatically under the hood?
BTW, if we need a JDK change I'd like to file a RFE with Sun but I don't understand the problem as well as you. Is it possible for you to file a RFE yourself or provide me with enough information to do so?
mentlicher, Is implementing http://bugs.sun.com/view_bug.do?bug_id=6588467 sufficient for this bug or do you need something else? I'd like to file a new RFE report if this one doesn't cover your requirements.
Well, in fact, I need http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4799761. There's a workaround - to fetch java.lang.Thread.daemon field, but that field is private, can be changed at any time and e.g. IBM's JDK have java.lang.Thread.isDaemon field. Method calls are not allowed e.g.on KVM (J2ME) and can be performed only in threads suspended by an event - not something we want do often and automatically.