Cassandra是否支持Java 10?

问题描述:

我们正计划将环境从Java 8迁移到OpenJDK10。在我的本地计算机上这样做,我发现Cassandra将不再为我启动,并出现以下错误:

We're planning on migrating our environment from Java 8 to OpenJDK 10. Doing this on my local machine, I've found that Cassandra will no longer start for me, giving the following error :

我在网上找不到任何可靠的信息,说它绝对不受支持

I can't find any solid information online that says it is definitely not supported.

此帖子来自4个月前的建议表明它们不支持Java 10,但没有说它已经得到证实,并且可以推断出更多。另一个用户也对此发表了评论,说他们已经设法使其在Java 11上运行。

This post from 4 months ago suggests that they do not support Java 10, but doesn't say it is confirmed, and is more inferred. There is also a comment on it from another user saying they have managed to get it running on Java 11.

此票表示:我们已更新了CI矩阵,使其包含Java 10,并且除上述OSGi测试外,其他所有方法都有效问题。我不确定该如何解决,但似乎暗示它已在Java 10上运行,因为该票证已标记为已解决。

The final comment on this ticket on datastax says "We've updated our CI matrix to include Java 10 and everything works except for the aforementioned OSGi testing issues." I'm not sure what to take away from that, but it seems to imply that it is working with Java 10 now, as the ticket is marked as resolved.

这张票,他们讨论了对Java 11的支持。甚至支持Java 10,但他们并没有给出是否支持的明确答案。

This ticket, they discuss support for Java 11. There are a few comments discussing the need to even support Java 10, but they don't really give a definitive answer on whether they will or not.

最后此博客讨论了一种使Java 11与cassandra一起使用的方法。但是我注意到这是使用Cassandra 4.0。这个正式发布了吗?我在他们的网站上注意到,他们说发布日期是tbd,说当前的稳定版本是3.11.3。 ,并且在他们的兼容性页面中没有提及。

Finally this blog discusses a way to get Java 11 working with cassandra. However I notice this is using Cassandra 4.0. Has this officially been released? I notice on their website they say the release date is tbd and says the current stable release is 3.11.3, and there is no mention of it on their compatibility page.

我目前通过Datastax在Windows上安装了Cassandra,但是我也尝试了克隆当前的git存储库并从那里运行它,但是我得到了相同的错误消息(尽管他们的github(他们似乎确实说过它仅在Java 8中经过了测试)。

I currently installed Cassandra on windows via Datastax, but I have also tried cloning the current git repository and running it from there, but I get the same error message (although on their github they do seem to say it has only been tested with Java 8).

那么他们根本不支持10个吗?另外,如果有人知道他们是否计划很快发布4.0,并且如果该版本肯定支持11(我认为是10?),那将是巨大的帮助。

Do they simply not support 10 then? Also if anyone knows if they plan to release 4.0 soon, and if that will definitely support 11 (and I assume 10 ?), that would be a massive help.

Cassandra 4.0对Java 8和Java 11都有明确的支持。实际上,它们甚至可以拆分配置文件,如下所示:

Cassandra 4.0 has explicit support for both Java 8 and Java 11. In fact, they even split-up the configuration files as such:

$ pwd
/Users/aaron/local/apache-cassandra-4.0-SNAPSHOT/conf
$ ls -a jvm*
jvm-clients.options jvm11-clients.options   jvm8-clients.options
jvm-server.options  jvm11-server.options    jvm8-server.options

支持这些特定版本的原因有两个。首先,几年来Java 8一直是Cassandra的实际标准。用户期望它将来仍将在Java 8上运行。

The reason for support of these specific versions is two-fold. First of all, Java 8 has been the de-facto standard for Cassandra for a few years now. Users expect that it will still work on Java 8 in the future.

鉴于Java,Java 9和Java 10的新发布周期为6个月,因此 当Apache Cassandra 4.0发行时。另外,在构建过程中运行的测试显示,他们选择使用哪种Java版本。因此,决定要支持4.0的Java 8和11,因为Java 9和10的工作似乎优先级较低。

Given the new 6 month release cycle of Java, Java 9 and Java 10 will no longer be "current" when Apache Cassandra 4.0 comes out. Plus, the tests which run during the build have shown to be picky about which version of Java they work with. Therefore, the decision was made to go support Java 8 and 11 for 4.0, as work on Java 9 and 10 seemed to be lower-priority.

这并不是说Cassandra 4.0无法在Java 9或10上运行。实际上, CASSANDRA-9608 甚至提交了一个补丁,将其覆盖。但是事实仍然存在,因为Java 8已在Cassandra用户群中长期使用。 Java 11将在4.0发行时成为当前的JDK / JRE。如果您想确保您的集群可以正常运行,我会选择这两个集群之一。

That's not to say that Cassandra 4.0 won't run on Java 9 or 10. In fact, CASSANDRA-9608 even has a patch submitted which should cover it. But the fact remains that Java 8 is included due to its longstanding use in the Cassandra user base. Java 11 will be the current JDK/JRE at the time 4.0 releases. If you want to be sure that your cluster will run well, I'd pick one of those two.

但是直到4.0,Java 8的最新补丁才真正出现。唯一的选择。

But until 4.0, the most recent patch of Java 8 is really the only option.