OpenHAB and future JDK versions. When?

I installed both JDK 17 and 18 and indeed it does not boot. Yet issue is not caused by openhab itself but underlying components (Karaf/Equinox).
Looking closer at the issue - seems JDK 17 removed one of very common, yet not officially supported mechanism called sun.misc.Unsafe. This caused issues for many things, including Equinox and Felix (https://issues.apache.org/jira/browse/FELIX-6430). I’d say that you’re safe up to 16, getting on Java 17 will require some more dependency updates.

In order to get up to JDK 17 you have to wait for Karaf to update Felix/Equinox to latest versions. Only then it will be possible to run whole thing on this release.

5 Likes

Small update - Karaf 4.3.3, released this (13 September 2021) morning is compatible with JDK 17. I just had a test spin and it loads nicely with Java 17.

Below screenshot for JDK 16, results are the same for 17 :wink:
image

1 Like

openHAB now uses Karaf 4.3.3. :slight_smile:

There is probably a lot more to fix so I’ve created an issue for this:

2 Likes