Anyone managed to run OpenEMS in GraalVM?

I’m currently trying to make a minimal image for OpenEMS that can run with minimal system requirements. JVM on it’s own is actually quite a large package and even headless requires a ton of dependencies.

I found a video (YouTube: “Deployment options for OSGi applications in the cloudedge” by the Eclipse Foundation; can’t post the link) about running OSGi using a custom JLink binary or using GraalVM to generate a native binary. However has anyone ever tried doing this with OpenEMS?

Background: I’ve tried building custom images using Buildroot for tiny embedded platforms like LuckFox Pico. While it is possible to install OpenJDK on it, it has a comically large dependency tree requiring glibc (musl not supported), cups, x11 etc. In the end OpenEMS launched but the startup took quite long (even though it seemingly worked fine after that).
But I haven’t managed to make the necessary modifications yet to run JLink or GraalVM mainly because I don’t have much knowledge about OSGi and BndTools.

Might also be interesting for people trying to create minimal Docker/Podman container images to safe on storage cost.

Interesting, I did not know about this. Will look into it if I find some time.

I’m posting the YouTube-link here (sorry for being restrictive to first-posters, we’ve got a lot of spam…)

2 Likes