-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Officially support Java 11. #12232
Officially support Java 11. #12232
Conversation
There aren't any changes in this patch that improve Java 11 compatibility; these changes have already been done separately. This patch merely updates documentation and explicit Java version checks. The log message adjustments in DruidProcessingConfig are there to make things a little nicer when running in Java 11, where we can't measure direct memory _directly_, and so we may auto-size processing buffers incorrectly.
I wonder if worth mentioning in the docs that there might be scary but harmless logs about things that can go away with the relevant jvm module flags |
@gianm should we call out the hadoop stuff and just caveat that? |
Probably, although I'm not sure what the call-out should say. It could just say that you may have issues with Hadoop indexing, since Hadoop 2.x on Java 11 isn't officially supported. I'll add that to the Hadoop indexing docs unless someone has a better idea. |
Good point. What are the flags? IMO, we should add them ourselves to the default jvm.config file. The flags will cause Java 8 to bomb out, so we'll need to either have two jvm.configs and have the startup script pick the right one, or add |
@gianm some are required to get JVM stats, e.g. https://github.com/apache/druid/blob/master/core/src/main/java/org/apache/druid/java/util/metrics/JvmMonitor.java#L169-L175 |
I think there's also some flag that stops these messages from happening:
I see them on all server startups when running on Java 11. They seem harmless but they look scary, like the cops are going to come and toss you in jail. |
@gianm are you planning to add those flags or do we want to do this as a follow-up? |
I think I should at least update the Hadoop docs. I can come back and do that next week. In the meantime, if anyone chimes in with knowing what flags are needed to quiet the warnings in #12232 (comment) then I can add those too. Otherwise we can do the flags in a follow up. |
@gianm To eliminate this warning, I think we can upgrade the guice from current 4.1.0 to the 4.2.2 which is the lowest version that supports Java 11. |
OK, it turns out I didn't have time to pursue those warnings after all. I'll merge this and then we can improve it in future patches. Still very exciting 😄 |
I made an further investigation on this. Guice to 5.0.1 (see the highlights) eliminates this warning. I noticed that there're some PRs(#11668, #10290, #10683) working on upgrading guava to new version, but they were blocked due to compatibility problem with hadoop 2. So, before we upgrade guava to newer version, we can't eliminate this warning by upgrading guice. |
Hmm. Thanks for the investigation @FrankChen021. It would be great to solve the guava/guice/hadoop2 problem. |
There aren't any changes in this patch that improve Java 11
compatibility; these changes have already been done separately. This
patch merely updates documentation and explicit Java version checks.
The log message adjustments in DruidProcessingConfig are there to make
things a little nicer when running in Java 11, where we can't measure
direct memory directly, and so we may auto-size processing buffers
incorrectly.