JavaFX 27 Native Image on a Raspberry Pi 5

(ennerf.github.io)

53 points | by 0x54MUR41 5 days ago ago

13 comments

  • exabrial 2 days ago ago

    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 2 days ago ago

    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 2 days ago ago

    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.

    • exabrial 2 days ago ago

      I don't think this is an accurate assessment. Oracle has its flaws and closet full of dead bodies/skeletons, but they've been good stewards of the JDK and JavaFX overall. Gluon and Oracle have done tremendous amount of work with JavaFX.

      Splitting it off the JDK was definitely the correct call. It's a Desktop UI framework, it should not be bound to JDK releases.

    • pjmlp 2 days ago ago

      Everyone that uses Java, because Oracle is responsible for about 70% of development efforts.

      https://insights.linuxfoundation.org/project/openjdk-jdk/con...

    • jfyi 2 days ago ago

      Their move from javafxports to graalvm left me dead in the water for android hardware support. Nobody was going to replace the hardware we were running on any time soon, so had to ditch them.

      That was forever ago, maybe it improved.

    • _benj 2 days ago ago

      You see JavaFX everywhere in finance software. I learned it from working on finance.

    • geokon 2 days ago ago

      JavaFX is supported by Gluon and not Oracle

      • pron 2 days ago ago
        • geokon 2 days ago ago

          Oh hmm, I'm honestly not super sure then. I know Gluon is the one that's seemingly has a business providing JavaFX support, while Oracle.. as far as I know doesn't offer a license or anything services in that direction? But I could be wrong. Gluon is mentioned in the article.. they have a very Qt-style confusing licensing situation where it's probably all free.. but you're never quite sure :)

          The whole space is a lot more icky than one would like it to be.. Which is unfortunate b/c while it doesn't have a billion features, it's a nice composable reactive framework to use (at least from cljfx/clojure)

          • pjmlp 2 days ago ago

            It is complicated.

            There was a time Oracle decided it wasn't worth the investment, note that it started as E3 scripting under Sun and it was only finalised after the acquisition.

            So a few Java champions took over it at Gluon.

            Then when Java 26 was released, Oracle reintroduced support for JavaFX,

            https://www.oracle.com/news/announcement/oracle-releases-jav...

            • geokon a day ago ago

              Oh huh, I guess it's pretty recent news. I wonder if it'll lead to new features. It's nice to see people are working on Native builds for instance, and that Graal integration is now an official priority of sorts.

        • reactordev 2 days ago ago

          It’s all a circle jerk in the JVM space