Updating a binding

I am developing two bindings, there will be more. Every time i add support for new channels, i have to delete Things and re-add them back, otherwise new channels aren’t available. It looks like OH caches available channels information together with Thing definition in its internal DB.
Is it possible to update that info somehow without re-adding Things? This is becoming quite annoying

As far as I understand that is the normal behaviour.
If it can be changed, I do not know (core developers would have to answer that)
Is it neccessary, I do not think so! While crerating a binding, creating additional channels might happen, however these intermediate changes would probably not be released to normal users (stable version). When it comes to the snapshot releases, such might be thinkable, however I would hesitate to do that and as a user of those snapshot version I would not expect that to happen that often!

It’s a known issue also annoying when you update your system and bindings are enhanced with new channels. So it would be nice if this will be fixed some day. There might be an issue about this somewhere, but I can’t remember. I vaguely think that if you create a thing in a things file you don’t have this problem.

Exactly, only managed things suffer from this. The reason is that the ManagedItemProvider is not checking the thing definition for already existing things but reads structure and configuration from the database. Unmanaged things are constructed from the XML and then the configuration is applied.

I tried to fix it but that is very difficult because we cannot distinguish between user-added (extensible) channels and channels that need to be removed because the thing structure changed (there is no flag for in the channel for that).

1 Like

What’s a managed thing and what makes it managed or not? Or does this refer to setting up by PaperUI vs text files ?

@J-N-K Well, i see removing channels that aren’t there any more is a problem, but i’m more concerned about adding new channels, because this is the major part of the inconvenience. I suppose you could fix at least this, and that would be good.

Exactly, text-file things are unmanaged (because you cant‘t edit them via the REST API), paper ui things are managed.