JDK-8249846 : Change of behavior after JDK-8237117: Better ForkJoinPool behavior
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.util.concurrent
  • Affected Version: 8u261,openjdk8u262
  • Priority: P2
  • Status: Resolved
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2020-07-22
  • Updated: 2024-04-30
  • Resolved: 2020-11-26
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 8 Other
8u261Fixed openjdk8u282Fixed
Related Reports
Relates :  
Relates :  
Relates :  
Relates :  
Description
Behavior of ForkJoinWorkerThread created by defaultForkJoinWorkerThreadFactory have changed after JDK-8237117.

AccessControlContext of the thread is set to the innocuousAcc with no permissions. Previous behavior was to inherit ACC from the thread that created ForkJoinPool. 

The change can be observed by user code, as shown by an example in attach

Please look for the start of discussion in JDK-8249677
Comments
URL: https://hg.openjdk.java.net/jdk8u/jdk8u/jdk/rev/0c39a12473c9 User: andrew Date: 2020-12-02 04:52:45 +0000
02-12-2020

URL: https://hg.openjdk.java.net/jdk8u/jdk8u-dev/jdk/rev/0c39a12473c9 User: mbalao Date: 2020-11-26 13:44:40 +0000
26-11-2020

Fix request (8u) I'd like to have this bug fix approved for 8u, as the release is affected by this regression which changes the previous behavior. There are users impacted. Risk is low because the fix is straight forward. The fix proposal has been review-approved here: https://mail.openjdk.java.net/pipermail/jdk8u-dev/2020-November/013094.html
25-11-2020

8u code review: https://mail.openjdk.java.net/pipermail/jdk8u-dev/2020-August/012459.html
27-08-2020

This issue (Change of behavior after JDK-8237117) is specific to the 8u release family, since the in behavior of JDK versions greater than 8 has not changed in the way described by this issue. I've added a couple of release not-applicable labels, e.g. 9-na.
31-07-2020

As it was mentioned in: https://bugs.openjdk.java.net/browse/JDK-8249677?focusedCommentId=14356806&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-14356806 This change of behavior has been introduced into 8u262 by 8237117, however, it was already there in other versions since JDK9+. As such, 11.0.7 and 14.0.1 (neither of them containing 8237117) will also fail this test. As Robert said, this is most likely the result of 8172726
22-07-2020