Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8327501: Common ForkJoinPool prevents class unloading in some cases #338

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

shipilev
Copy link
Member

@shipilev shipilev commented Mar 7, 2024

The change is stabilizing in mainline, but it looks simple, so we start testing it for JDK 21 pickup here.

Additional testing:

  • Linux x86_64 server fastdebug, all

Progress

  • JDK-8327501 needs maintainer approval
  • JDK-8328366 needs maintainer approval
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Issues

  • JDK-8327501: Common ForkJoinPool prevents class unloading in some cases (Bug - P4 - Approved)
  • JDK-8328366: Thread.setContextClassloader from thread in FJP commonPool task no longer works after JDK-8327501 (Bug - P3 - Approved)

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk21u-dev.git pull/338/head:pull/338
$ git checkout pull/338

Update a local copy of the PR:
$ git checkout pull/338
$ git pull https://git.openjdk.org/jdk21u-dev.git pull/338/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 338

View PR using the GUI difftool:
$ git pr show -t 338

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk21u-dev/pull/338.diff

Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Mar 7, 2024

👋 Welcome back shade! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot changed the title Backport 53c4714aab2e072ba18631875dcaa3b2d5d22243 8327501: Common ForkJoinPool prevents class unloading in some cases Mar 7, 2024
@openjdk
Copy link

openjdk bot commented Mar 7, 2024

This backport pull request has now been updated with issue from the original commit.

@shipilev shipilev marked this pull request as ready for review March 7, 2024 10:15
@openjdk
Copy link

openjdk bot commented Mar 7, 2024

⚠️ @shipilev This change is now ready for you to apply for maintainer approval. This can be done directly in each associated issue or by using the /approval command.

@openjdk openjdk bot added the rfr Pull request is ready for review label Mar 7, 2024
@mlbridge
Copy link

mlbridge bot commented Mar 7, 2024

Webrevs

@jerboaa
Copy link
Contributor

jerboaa commented Mar 12, 2024

Lets wait on getting this one backported until the compatibility impact wrt. setting the context class loader of a thread in the common pool is addressed.

@shipilev shipilev marked this pull request as draft March 12, 2024 09:41
@shipilev
Copy link
Member Author

Lets wait on getting this one backported until the compatibility impact wrt. setting the context class loader of a thread in the common pool is addressed.

Yup. With this PR, I just confirmed all tests that I throw at this change pass in jdk21u-dev.

@openjdk openjdk bot removed the rfr Pull request is ready for review label Mar 12, 2024
@openjdk
Copy link

openjdk bot commented Mar 13, 2024

@shipilev This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8327501: Common ForkJoinPool prevents class unloading in some cases
8328366: Thread.setContextClassloader from thread in FJP commonPool task no longer works after JDK-8327501

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 10 new commits pushed to the master branch:

  • 0e9b9f2: 8310072: JComboBox/DisabledComboBoxFontTestAuto: Enabled and disabled ComboBox does not match in these LAFs: GTK+
  • 0d9833e: 8323552: AbstractMemorySegmentImpl#mismatch returns -1 when comparing distinct areas of the same instance of MemorySegment
  • 0dcbc1d: 8324668: JDWP process management needs more efficient file descriptor handling
  • 42e6a97: 8323670: A few client tests intermittently throw ConcurrentModificationException
  • 55e97ce: 8319773: Avoid inflating monitors when installing hash codes for LM_LIGHTWEIGHT
  • b56f0c0: 8326106: Write and clear stack trace table outside of safepoint
  • 8d4f686: 8312229: Crash involving yield, switch and anonymous classes
  • 2a21044: 8331573: Rename CollectedHeap::is_gc_active to be explicitly about STW GCs
  • 362ecac: 8331164: createJMHBundle.sh download jars fail when url needed to be redirected
  • dc8b95f: 8328075: Shenandoah: Avoid forwarding when objects don't move in full-GC

Please see this link for an up-to-date comparison between the source branch of this pull request and the master branch.
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@shipilev shipilev force-pushed the JDK-8327501-fjp-classloader-leak branch from f17aeca to 6718471 Compare April 8, 2024 07:06
@shipilev
Copy link
Member Author

shipilev commented Apr 8, 2024

/issue add JDK-8328366

@openjdk openjdk bot removed the clean label Apr 8, 2024
@openjdk
Copy link

openjdk bot commented Apr 8, 2024

@shipilev
Adding additional issue to issue list: 8328366: Thread.setContextClassloader from thread in FJP commonPool task no longer works after JDK-8327501.

@shipilev
Copy link
Member Author

shipilev commented Apr 8, 2024

Both backports are clean.

/clean

@openjdk openjdk bot added the clean label Apr 8, 2024
@openjdk
Copy link

openjdk bot commented Apr 8, 2024

@shipilev This backport pull request is now marked as clean

@shipilev shipilev force-pushed the JDK-8327501-fjp-classloader-leak branch from 0c1d5d9 to febeb48 Compare May 30, 2024 09:38
@shipilev shipilev marked this pull request as ready for review May 30, 2024 14:16
@openjdk openjdk bot added the rfr Pull request is ready for review label May 30, 2024
@shipilev
Copy link
Member Author

/approval 8327501 request Fixes the class unloading regression since JDK 19. Applies cleanly. Tests pass, but there is a regression, which is fixed by JDK-8328366. Risk is medium: affects common paths, has bugtail with easily detectable failures.

/approval 8328366 request Fixes the regression introduced by JDK-8327501. Applies cleanly. Tests pass.

@openjdk
Copy link

openjdk bot commented May 31, 2024

@shipilev
8327501: The approval request has been created successfully.

@openjdk
Copy link

openjdk bot commented May 31, 2024

@shipilev
8328366: The approval request has been created successfully.

@openjdk openjdk bot added the approval label May 31, 2024
@openjdk openjdk bot added ready Pull request is ready to be integrated and removed approval labels Jun 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport clean ready Pull request is ready to be integrated rfr Pull request is ready for review
2 participants