JavaFX 27 on a Raspberry Pi 5 Outruns a Ryzen 9 Desktop
JavaFX 27 Native Image on a Raspberry Pi 5

GraalVM Native Image can make JavaFX desktop apps start up to 90% faster and use 55% less memory. The catch: JavaFX's dynamic nature makes AOT compilation tricky, and existing tools like Gluon Substrate and Liberica NIK lag behind the latest releases. HEBI built StaticFX, a GraalVM feature that runs on the stock toolchain and supports JavaFX 27 with Oracle GraalVM on a Raspberry Pi 5.
Starting the AtlantaFX sampler on a high-end Ryzen 9 9950X desktop with jlink + CDS takes more than 2.5 times as long (1.3 s) as the same application running AOT-compiled on a tiny Raspberry Pi 5 (0.5 s).
- exabrial
One thing I think that's needed with JavaFX is integrations with DI frameworks! I started a project called DiFx that does exactly that: https://github.com/exabrial/DiFx
This makes state and shared data management in JavaFX much nicer, as you offload those concerns to a container. CDI also provides extensive capabilities with portable extensions and scope management, as well as a sync and async eventing framework.
The problem is that I don't have a "real life" project to try this out on, so development kinda slumped off.
- geokon
Thanks for writing this up! It still assumes a lot of prior knowledge, but it's a good starting point to approaching these problems. How JavaFX works on different platforms really looks like dark magic from the outside. I wrote an app in Clojure using cljfx. I can jpackage it and run it Linux/Windows/macOS .. it's quite easy to get working. But once you step outside of the standard platforms it gets complicated really fast. Trying to get it to Android or a native build and suddenly you have to be an expert in several build systems and JVM internals.
- giancarlostoro
Apparently JavaFX didnt die as we all thought back when Oracle spit it out of the JDK, they will happily offer support for it now, but who wants to be in bed with Oracle.
That looks really sleek. One thing JavaFX got right was CSS support.