Replies: 2 comments
-
Java 11 OR HIGHER ... The CI builds for Ebean run against 11, 17 GA and EA. Currently GA is 20 and EA is 21 Early Access and this moves automatically as the GA and EA versions increase, say when 21 comes out then GA will be 21 and EA will be the 22 Early Access. Just to say this is enabled by Oracle providing the EA, GA GitHub actions. So in this way, people should be pretty comfortable using Ebean 13.x with any JDK that is 11 or higher (heck, that even includes the Early Access release which today is Java 21 EA). ebean-agentThe main note about using later versions of JDK is that the Bytecode version increases. The ebean-agent uses the ASM library (it repackages it and includes it in ebean-agent) and this allows the ebean-agent to support the latest Bytecode and also older Bytecode. The ebean-agent actually supports Java 8 and higher [and it must continue to support Java 8]. The latest version of ebean-agent (say 13.17.4 today) is expected to support Java 8+ and can be used with Ebean v11.x, Ebean v12.x and Ebean v13.x. For example, we should be able to use ebean-agent 13.17.4 with ebean 12.x (and people using the latest version of the IntelliJ plugin will indeed be doing this, this is all expected and good). So we also expect to be able to use Java 20 with ebean-agent 13.17.4 + ebean 12.x. Supporting latest Java versionEbean supporting the latest Java version really translates into:
There are probably not docs for this no. Yes, Ebean v12.x should be able to be used with Java 11. I know of no reason why it would not work. Moreover, Ebean v12.x should also with Java 20 AS LONG AS we use ebean-agent 13.17.1+ to do the Bytecode enhancement. I know of no reason why that would not work.
Yes, log bugs. Note that the first thing someone needs to do is confirm that the bug still exists in the latest version of ebean. So yes create a test case, then bump to ebean latest and confirm if the issue still exists. Then log it with the results of that. I feel it is extremely unlikely that an issue in Ebean 12.x will be related to the Java version. Cheers, Rob. |
Beta Was this translation helpful? Give feedback.
-
Many thanks for such a detailed answer! The additional detail I was able to find was the fact that the entire code block is being called from a Java stream using
As soon as I removed the speculative I've tried to reproduce this in an isolated environment without much success, sorry about that. |
Beta Was this translation helpful? Give feedback.
-
https://ebean.io/docs/getting-started/ says Java 11 is required for Ebean v13 or later.
Is there any piece of documentation which suggests whether Java 11 can be used with Ebean v12?
To avoid XY problem. We're using Playframework v2.8.17 on Java 11.0.17.
https://github.com/playframework/play-ebean suggests that the newest supported version of Ebean is 12.16.1 which is what we use. And if you look at the official Playframework documentation they say Java 11 is supported.
That said, I've noticed odd bugs, such as:
Here what happens in MyPojo.java:122 is that we're calling
foos
in the above example is a managed list of entities. Exception seems to happen when this list is empty.There are other scenarios too, e.g.
new ArrayList<>(managedListOfEntities)
and so on.Should I be reporting individual bugs for such cases or ebean v12 doesn't work with Java 11 by definition? Many thanks.
Beta Was this translation helpful? Give feedback.
All reactions