I’m developing the Nanoleaf Binding and I am encountering a strange situation on one of my installations (on others it does work quite will).
the binding is installed (as being said by Openhab logs)
Karaf tells me that the feature is started / activee and the bundle as well
However, It doesn’t seem to work nor do I see any logs of my binding even though I am sure I have set the bundle to debug or even trace
(I am pretty sure I am using the right expression “log:set TRACE org.openhab.binding.nanoleaf” as I am using that on other installions as well).
Even when I start the discovery it stops much faster with the discovery as usual (normally it tries about 30 secs where in this case it stops already after 2 secs) and even though I have debug logs in all AbstractDiscoveryService-Methods, there is no log output at all.
I have stopped and (re)started the feature as well as the bundle in the openhab console with no success
When starting the bundle there is no exception in the logs that would hint to an issue.
Usually the bundle is pretty chatty when I set it to TRACE or DEBUG but I see nothing.
Other bundles do work
So my question is
What could be the case that a binding is installed but doesn’t really run?
Any idea how I could further analyze the root cause?
I am on 2.5.1 on that system. Yes I did with karaf . I also thought there might be a missing dependency but then there must have been an exception but as I said I see nothing.
To be exact: The runtime environment has been installed with 2.5.1 and I had issues with my binding on 2.5.1 (as well). So I built my latest bundle which has even more log statements and this one is as follows.
So the behaviour is not related to being new.
20 │ Active │ 80 │ 2.8.2.v20180104-1110 │ Gson: Google Json Library for Java
There is no difference in behaviour of using my 2.5.1 bundle or the 2.5.2 unfortunately (even though as you said 2.5.2 could have dependency issues with 2.5.1 and then I would be happy to see them ).
“does the bundle come up in Eclipse?”
Not sure what you mean with “eclipse” in that sense. I can see it liste in karaf as being installed and active.
I should mention that both run perfect on my own local home environment as well as on the one of my bundle development partner. So I don’t think it is a general problem with the bundle but it seems to be related to that environment on which it is currently running. I would rather find out the root cause of that as there might be others that would also have the same setup and then I would be even more blind to find out why there is an issue (currently I have full access myself to that box).
I have just developed a binding but others have had the same issue that the binding doesn’t load. Developed in vscode 2.5.2snapshot. I’m new to all this so didn’t know if I had to add anything in anywhere such as Gson for it to be used. Or if it would be backwards compatible with say 2.4/2.3?
It works perfectly on my bare 2.5 system (albeit with a few other addons installed but not setup)
So I tried this finally but even this had no effect. Neither the bundle tells me anything nor do I see any exception. btw, I even compared the log settings to what I have at home and they are equal (for transparency reasons I should mention I run openhabian at home).
In the meantime I also updated the basic linux system (hypriot) which had no effect.
Tomorrow I try to update openhab to 2.5.1-2. I’ll keep you all posted if that has an effect. Maybe someone could even point me to a documentation how I do that update on a linux environment (actually openhab runs in a docker container based on hypriot there).
More and more I had the feeling that something was wrong with the discovery and the mdns and finally this proved to be true. Due to the normal setup of a docker container only configured ports will be open to the public which is a killer for mdns (or upnp).
The really simple solution that has cost me hours and days to find out is the following:
You see, this is the point with documentation. Usually the solution for your problem is somewhere documented if you how to ask the right question
In hindsight I can say that I did not setup the docker container myself and the one who did probably wasn’t aware of that documentation (no excuse). So it is good that you again directed to that point in the documentation.
At least I learned a lot (and maybe the docker syntax above is a bit of a value for someone).