-
Enhancement
-
Resolution: Won't Fix
-
P4
-
8u74
-
None
-
generic
-
generic
Something that was overlooked by JEP 102: Process API Updates, where we finally get access to the PID, is that native Thread IDs are still inaccessible.
There are many reasons that we would want access to the native thread ID. One being to set or query processor affinity which can have significant impact in NUMA machines.
This should be a safe and simple addition to the ThreadInfo object. the data is available from HotSpot thread dumps, so with a JDK installed it can be parsed from a text dump obtained through the Attach mechanism and calling sun.tools.attach.HotSpotVirtualMachine.remoteDataDump(). But of course that class is not part of the public API either, and parsing the text output is an awkward hack.
There are many reasons that we would want access to the native thread ID. One being to set or query processor affinity which can have significant impact in NUMA machines.
This should be a safe and simple addition to the ThreadInfo object. the data is available from HotSpot thread dumps, so with a JDK installed it can be parsed from a text dump obtained through the Attach mechanism and calling sun.tools.attach.HotSpotVirtualMachine.remoteDataDump(). But of course that class is not part of the public API either, and parsing the text output is an awkward hack.