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

Avoid capturing ACC when not necessary #108

Merged
merged 1 commit into from
Jul 30, 2021
Merged

Avoid capturing ACC when not necessary #108

merged 1 commit into from
Jul 30, 2021

Conversation

Sanne
Copy link
Contributor

@Sanne Sanne commented Jul 30, 2021

We can avoid capturing the AccessControlContext when MBeans are disabled.

The acc field is holding a reference to the classloader, which is leading us to have a classloader leak in Quarkus during some integration tests - in some cases it leads to critical failures as we exhaust memory on CI.

There might be better ways to avoid the CL leak in Quarkus but this seems easy enough and useful anyway?

@@ -1859,7 +1861,7 @@ void completeTermination() {
waiters = waiters.getNext();
}
tail.setNext(TERMINATE_COMPLETE);
if (! DISABLE_MBEAN) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

native-image can no longer DCE this path, which can result in failures due to JMX now being reachable.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ouch, sorry!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants