-
Notifications
You must be signed in to change notification settings - Fork 25.7k
Add early-access check #23743
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
Add early-access check #23743
Conversation
The OpenJDK project provides early-access builds of upcoming releases. These early-access builds are not suitable for production. These builds sometimes end up on systems due to aggressive packaging (e.g., Ubuntu). This commit adds a bootstrap check to ensure these early-access builds are not being used in production.
abeyad
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, left a nit and a question
| final String javaVersion = javaVersion(); | ||
| return javaVersion.endsWith("-ea"); | ||
| } else { | ||
| return false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: return "Oracle Corporation".equals(jvmVendor()) && javaVersion().endsWith("-ea") more succinct?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I pushed 6cf944e.
|
|
||
| public void testEarlyAccessCheck() throws NodeValidationException { | ||
| final AtomicReference<String> javaVersion | ||
| = new AtomicReference<>(randomFrom("1.8.0_152-ea", "9-ea")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why does this need to be an AtomicReference?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because I set it to a different value further down in the method to simulate a check where the Java version is not an early-access build.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
++, i didn't realize it was just one instance of the EarlyAccessCheck
The OpenJDK project provides early-access builds of upcoming releases. These early-access builds are not suitable for production. These builds sometimes end up on systems due to aggressive packaging (e.g., Ubuntu). This commit adds a bootstrap check to ensure these early-access builds are not being used in production. Relates #23743
|
Thanks @abeyad. |
The OpenJDK project provides early-access builds of upcoming releases. These early-access builds are not suitable for production. These builds sometimes end up on systems due to aggressive packaging (e.g., Ubuntu). This commit adds a bootstrap check to ensure these early-access builds are not being used in production. Relates elastic#23743
The OpenJDK project provides early-access builds of upcoming releases. These early-access builds are not suitable for production. These builds sometimes end up on systems due to aggressive packaging (e.g., Ubuntu). This commit adds a bootstrap check to ensure these early-access builds are not being used in production. Relates elastic#23743
The OpenJDK project provides early-access builds of upcoming releases. These early-access builds are not suitable for production. These builds sometimes end up on systems due to aggressive packaging (e.g., Ubuntu). This commit adds a bootstrap check to ensure these early-access builds are not being used in production.
Relates #23668