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

Remove AccessController usage for enum adapter #2704

Merged

Conversation

Marcono1234
Copy link
Collaborator

Purpose

Resolves #2686

Description

See #2686 and the discussion there

This pull request removes the AccessController usage, assuming most users don't depend on it and because it has been marked for removal in the JDK.

Also adds a new test for serialization of a JDK enum class to make sure the adapter works correctly despite strong encapsulation of JDK internals (JEP 403).
Though the test is not directly related to the AccessController removal.

SecurityManager and AccessController are marked as deprecated for removal
in the latest JDK versions, see https://openjdk.org/jeps/411.
Additionally this code was originally added providently but it is not clear
if or how many users actually depend on it.
@eamonnmcmanus eamonnmcmanus merged commit 00028fb into google:main Jun 18, 2024
11 checks passed
@Marcono1234 Marcono1234 deleted the marcono1234/remove-AccessController branch June 23, 2024 20:56
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.

Implement fallback if class java.security.AccessController does not exist
2 participants