It seems that the JavaFX libraries are no longer included in KNIME 4 (tested with today’s nightly build on macOS). This means, the jBrowserDriver plugin for the Selenium Nodes (which requires JavaFX) will break:
thanks for the feedback. From my research, these packages are not available for Java 8; the minimum is 11 (I checked this option yesterday, as I had a similar issue on our CI environment with OpenJDK)
If that’s true then we are out of luck I could do more research but it seems you have done quite some already.
We’ve been considering bumping to Java 11 but then decided not to as Java 8 is well supported and there wasn’t any apparent reason. This may change in the future.
According to various tickets (eg. here), there seem to be some more or less brittle solutions to get JavaFX into an OpenJDK (no one’s talking about licensing implications… not sure whether this is a good sign). All in all, this feels like a huge rabbit hole which I’m not willing/able to explore now.
Instead I’ll drop the jBrowser plugin from the upcoming 4.0 release.
From a quick browse it looks like we may need to build openjfx8 and make an osgi bundle providing the windows, macos and Linux libraries. Both adopt openjdk8 and amazon corretto currently have open issues w.r.t to javafx.
Alternatively a user could swap out the bundled jre for one containing javafx (an older oracle distro or a jre11 with the openjfx libs) but that’s not really a viable solution.
I looked at that thread too - it looks like they are working back from v11 backwards, but they were aiming for end of Q1 this year for v8, which has obviously slipped significantly… Good luck!
I found that same link. Here’s a solution for Java 8:
It involves a kitchen sink full of build requirements and patching files. And these instructions are only for Windows (so, someone would need to port this and make it work on Linux/macOS as well). And then, all of this would then need to be wrapped in OSGi plugins and fragments
In my case, the JavaFX dependency is in an additional plugin for the plugin, so I decided to rather strip this out to get a working 4.0 release with 99% of the functionality.
Anyways, I’d still be willing to contribute / cooperate as good as I can to find a common solution.
You have to point it to the JRE of an existing KNIME 4.x installation. The JRE is a feature and part of the update site but it cannot be used when starting from an SDK.
If anyone else stumbles into JavaFX issues in KNIME v4 a solution that appears to be working for me is to switch to use the Amazon Corretto JRE (or an older Oracle JRE) and updating the knime.ini to:
-vm
jre8/bin
My JavaFX Eclipse views, node dialogs and cell renders appear to be working as expected and I’ve not noticed any unexpected behaviour.
Hopefully this can be avoided when Java 11 or newer becomes the embedded JRE.
To loop back into an old topic a bit. With the upgrade to Java 11 in KNIME 4.4 it seems to now be possible to add JavaFX as an OSGi dependency and I’ve been able to get my JavaFX integrations working without needing to bundle a custom JRE.