JDK-8356870 : HotSpotDiagnosticMXBean.dumpThreads and jcmd Thread.dump_to_file updates
  • Type: Enhancement
  • Component: core-svc
  • Priority: P3
  • Status: Open
  • Resolution: Unresolved
  • Submitted: 2025-05-13
  • Updated: 2025-05-25
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
tbdUnresolved
Related Reports
CSR :  
Duplicate :  
Duplicate :  
Relates :  
Sub Tasks
JDK-8357650 :  
Description
The thread dump generated by HotSpotDiagnosticMXBean.dumpThreads and jcmd Thread.dump_to_file has several updates in the loom repo that should be brought to main line:

1. The implementation is changed to use a thread handshake to get a consistent snapshot of each thread.

2. The updated thread dump includes the thread state, the object if a thread is blocked on monitor enter, the parkParker if the thread is parked, the owner when the parkParker is an ownable synchronizer, and the frames where object monitors have been entered.

3. If HotSpotDiagnosticMXBean.dumpThreads throws IOException but not when writing to the file system fails. This should be fixed.

4. HotSpotDiagnosticMXBean.dumpThreads links to a JSON schema that describes the JSON format.
Comments
A pull request was submitted for review. Branch: pr/25425 URL: https://git.openjdk.org/jdk/pull/25429 Date: 2025-05-24 06:57:56 +0000
25-05-2025