This content has been marked as final. Show 3 replies
ThreadGroups are still present and mentioned in the RTSJ - in particular that scope-allocated NHRT/RTT wont be a member of any ThreadGroup.
Are you referring to the fact that the NHRT/RTT constructors don't let you specify the ThreadGroup? That is true - the ThreadGroup is determined by the ThreadGroup of the current thread (or perhaps the security manager).
ThreadGroups really serve little purpose in Java and have been allowed to "bit-rot" - their use while not actually deprecated is strongly discouraged (see for example "Effective Java" by Josh Bloch).
jcamerico wrote:No, a thread's ThreadGroup is determined at construction time, so if you want threads in specific groups then you have to create them from a thread already in that group.
Thank you, David. Actually it's exactly that : we can't specify a ThreadGroup through a RTT constructor. I was wondering if there was something like a method setThreadGroup instead to keep the compatibility, but i don't think so.
What functionality do you want from the ThreadGroup?