B4J Question OpenJDK 17 or 19? JavaFX SDK 17?

aeric

Expert
Licensed User
Longtime User
I understand that the recommended version for B4J (current version 9.80) is OpenJDK 11.
Should I combine javafx17 with openjdk17?
Or can I leave open jdk11?

Better to use jdk11 or 14.


Note that you can use any version of OpenJDK you like. You just need to download the three pieces and put them in the right place:
- OpenJDK
- JavaFX SDK + jmods: https://gluonhq.com/products/javafx/

JavaFX SDK should be in javafx folder.
JavaFX jmods should be in javafx\javafx-jmods folder

So, is it a good time to use newer version?

If yes, version 17 or 19?
Do I need to choose OpenJDK 17 since JDK 17 is LTS version? and because JavaFX 17 is also LTS version?

Can I mix OpenJDK 19 with JavaFX SDK 17?

Does it have any effect to B4JPackager11?
 

peacemaker

Expert
Licensed User
Longtime User
I haven't test compiling under Linux
I have just started my server app project (via B4JBridge) on a remote Linux host by OpenJDK19 bundle - works OK as before with OpenJDK14.
(under Windows an UI app is also OK).
 
Last edited:
Upvote 0

aeric

Expert
Licensed User
Longtime User
Should be possible if you pass --enable-preview as a JVM argument, however it means that your app will not run without it.
Already passed --enable-preview but seems no effect to the compiling.
 
Upvote 0

tchart

Well-Known Member
Licensed User
Longtime User
Just wanted to point out that you should really only use LTS versions of Java Runtime (Long Term Support). Otherwise you might find the required JRE doesnt get security fixes any more.

Only Java 11 and 17 are LTS.

Java 11 is supported till 2026
Java 17 is supported till 2029

See here;
 
Upvote 0

aeric

Expert
Licensed User
Longtime User
For JDK 17:

OpenJDK 17.0.2 (choose Windows / x64 zip and extracted as jdk-17.0.2 folder under C:\Java or your preferred directory)
Download: https://jdk.java.net/archive/

JavaFX 17.0.2 (extract the SDK to jdk-17.0.2 directory extracted above as javafx folder, jmods into this javafx directory as javafx-jmods)
Download: https://gluonhq.com/products/javafx/

1675849494403.png


1675849422950.png
 
Upvote 0
Top