JDK-8231209 : [REDO] JDK-8207266 ThreadMXBean::getThreadAllocatedBytes() can be quicker for self thread
  • Type: Enhancement
  • Component: core-svc
  • Sub-Component: java.lang.management
  • Affected Version: 14
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: generic
  • Submitted: 2019-09-19
  • Updated: 2020-12-04
  • Resolved: 2019-09-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.
JDK 11 JDK 13 JDK 14 Other
11.0.10-oracleFixed 13.0.6Unresolved 14 b17Fixed openjdk8u282Fixed
Related Reports
CSR :  
Relates :  
Relates :  
Sub Tasks
JDK-8231210 :  
Description
JDK-8207266 added a new method named getCurrentThreadAllocatedBytes to the com.sun.management.ThreadMXBean interface, but did not provide a default implementation. Many tests implement this interface and thus fail to compile. A fix is to provide a default implementation that throws, vis.

public default long getCurrentThreadAllocatedBytes() {
    throw new UnsupportedOperationException();
}

The failing tests should be updated to implement getCurrentThreadAllocatedBytes.
Comments
Fix request (13u) Requesting backport to 13u for parity with 11u. CSR for 13u is approved: JDK-8257412. The patch applies cleanly but it requires some modifications. Tested with ThreadMXBean tests and tier1. RFR approval: http://mail.openjdk.java.net/pipermail/jdk-updates-dev/2020-December/004343.html
04-12-2020

Fix Request (8u). This is first of a pair of backport requests: the other is JDK-8231968, which fixes a bug in JDK-8231209. For this patch, see the approved CSR JDK-8247812 for compatibility and risk discussion. Review approval: https://mail.openjdk.java.net/pipermail/jdk8u-dev/2020-September/012673.html
15-09-2020

Paul has this comment in the JDK 11 backport issue for clarity (JDK-8247806): Fix Request (11u). This is first of a pair of backport patches: the other is JDK-8247809. For this patch, see the approved CSR JDK-8247807 for compatibility and risk discussion. The patch applies cleanly.
10-07-2020

URL: https://hg.openjdk.java.net/jdk/jdk/rev/c29e49148be7 User: phh Date: 2019-09-25 22:22:50 +0000
25-09-2019