Plex binding for OH3 | Will it be ported?

It appears that the binding requires Java 17. @aronbeurskens, is that what you’re running? OpenHAB has switched to Java 17 for 4.0 and may explain why it works for him and not us. I have the same issue but can’t switch over to 17 to test at present. @Hendrik_Nielsen, you could try that.

Hi, thanks for explaining :slight_smile:
Since I am use Openhab on Docker is there any chance I can switch to that java version?

If you are running openHAB 3.x, a switch to Java17 will not help but might give you more trouble.
There had been a lot of adjustments been made to make openHAB 4 fully Java17 compatible.

Alright.
Basically there should be a OH 3.4 and a OH 4 Version of the binding then?

If it shall run on both versions, yes!

I just found this in another thread:

I’ll try this out.
Hope that @aronbeurskens could maybe include this in future versions of the binding?

Thanks for your support!

Yes I am running Java 17, which explains the difference. People can use @morph166955 version for now and I will try to get a java 13 setup for next / future releases.

1 Like

To compile a 3.2.0/4.0.0 binding:

  1. Re-add the binding folder that you had before (don’t delete addon.xml). Having it won’t really hurt anything on 4.0.0 for the moment, but it’s required for 3.2.0
  2. mvn clean install -pl :org.openhab.binding. -Dohc.version=3.2.0 -Dmaven.compiler.source=11 -Dmaven.compiler.target=11

That should generate a jar compatible for all versions. I’ve been using it for a while on the androidtv binding and it seems to be ok. Just be aware, if you have any newer java features (above v11) you will have issues.

2 Likes

Thank you for the information, will use it!

No, openHAB 3.x requires Java 11, versions above are not supported !

Did not directly see that you already wrote about issues with versions other than Java11…

Plex Bining is showing up again, can add a server thing, but when adding a player via scan, it finds the players, but then they show:

Status:

UNINITIALIZED

**BRIDGE_UNINITIALIZED**

Also the log is spammed with

[WARN ] [ex.internal.handler.PlexApiConnector] - Getting session data

Same problem here with players staying UNINITIALIZED. I’m on 3.4.1 with Java 11 using @morph166955 binding…

Same problem here, log WARN and players staying UNINITIALIZED. Equally on 3.4.1 with Java 11 using @morph166955 binding…

Since not everyone is having this issue I’m just wondering if the common link is using Plex via Docker (I’m using PlexInc image) ?

I’m not using docker. It’s openhab on Debian in a proxmox container…

I have indeed deployed my Plex Server as a docker container. Image is the LInuxservers.io.

Has anyone found a solution to this?

Good news, the PR has finally been merged into main. The binding will soon be available in OpenHAB version 4

2 Likes

Lets gooooooooo!
(And I’m still stuck in 3.3 ._. )

What is blocking you from upgrade?