-
Notifications
You must be signed in to change notification settings - Fork 81
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 DisableIntrinsic for currentThread #5295
Remove DisableIntrinsic for currentThread #5295
Conversation
Noticed during #5294 I think a sufficient amount of time has passed where we can change the defaults and assume the runtime is using a JVM 11.0.17+, 17.0.5+. In cases where that is not true, the user can add |
I think this may be a moot point, b/c afaict, this settings to only be affecting development, and not hitting |
Given how hard this was to track down, I'd hate to subject any downstream user to it. Could we test the current java version to warn if a version is found that could be affected by this, and instruct them to add their own vm options? I can't imagine this will be the last time we hit a JVM bug, so it would come in handy in the future as well... |
I originally sketched out something that would have printed out the recommended arguments based on JVM version; devinrsmith@f9ffc27. This would introduce an extra process on startup, and I never took it further. An alternative would be a warning on startup as you suggest @niloc132. A stricter version of this might even throw an error and stop the startup. I might prefer the stricter variant, with some sort of option to downgrade it to a warning. All that said, I don't think we are actually applying the disable intrinsic today. I could go back through the history to see if there was a partial or accidental remove of it... |
Recalling a bit, I think it was kept out of the start script, as the primary consumer of that was our docker image layer (where we deployed a specific version of java and could apply the workaround only if necessary). Wrt starting the JVM from embedded-server / python, we could use the |
I would lean to the strict version or auto-inject the JVM arg based on version. Most users don't look at the logs closely unless something goes really bad, and even then they just look at logs local to the error message. |
Provides a framework for adding Deephaven safety checks on startup. Currently, the only safety check is https://bugs.openjdk.org/browse/JDK-8287432. We could consider adding other safety checks; for example, throwing errors when we know a Java version is not longer supported.
I've added a safety check layer that runs on startup, and have tested it natively and from py-embedded-server contexts successfully. There is the ability to disable all safety checks, or safety checks individually. I've also added what may be seen as a controversial JDK_END_OF_LIFE safety check; this is a safety check that is conditioned based on the current date. If we think this is too aggressive, we could relax EOL by some fixed amount (6 months?), or delete it. I suspect that DHE would always want to disable it. |
Wrt the intrinsic, this is what it looks like running from the native application (would be very similar in docker as well):
Here's what it looks like from embedded python:
|
I've added a 1-year grace period post EOL, which seems like a more reasonable default. |
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.
Trying to avoid any bikeshedding... so I approved as-is. If we end up adding a few more of these I might have some thoughts, but this will definitely do the job.
I've removed |
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.
Did you test the safety checks on a vulnerable version and on current to ensure the messages are printed appropriately?
Yes |
Adding documentation needed, mainly as key for DHE consideration. |
Labels indicate documentation is required. Issues for documentation have been opened: Community: deephaven/deephaven-docs-community#184 |
Fixes #2500