Hello,
I am migrating to OH3.1 and I’d like to keep textual definitions. However, I am struggling to get my MQTT Setup in a text file and the Main UI definitions.
Whenever I modify something on the UI this huge json file is changed:
./userdata/jsondb/uicomponents_ui_page.json
All pages go in here. Is it possible somehow to have the main ui config in the conf folder and hierarchic (meaning a json file per page for example)?
in OH 2.x the mqtt broker could be defined here:
conf/services/mqtt.cfg
Seems not be possible either.
Now the mqtt definitions using the automatic approach go here:
./userdata/jsondb/org.openhab.core.thing.Thing.json
Err, no. That was in OH 1.x (or in compatibility mode).
MQTT for OH 2.3 and newer is different since this was implemented.
Well in theory you should be able to define any Thing via .thing file.
You “just” have to figure out the format. Haven’t tried with MQTT but there’s a section in the link I gave above.
The experimental file config simulation of things and items defined in UI is hanging up in the air since April. We all should force @mstormi and openhab band to pay some attention to this, as this is a necessary feature.
@11194, I’d appreciate if you could reconsider your choice of words. No one can “force” any of our volunteers to do anything, and the mere suggestion shows a lack of respect for Markus and all of the developers and maintainers who put their own time and effort into this project.
If you don’t like what’s going on with openHAB, no one will “force” you to use it. If you think you’re owed something because you downloaded free software, then you’re wrong. The only thing we owe each other here is mutual respect.
I hope I’ve misread your intention, in which case I apologize for over-reacting. However, in my 2.5 years in this community, I don’t recall anyone ever suggesting that users should try to force developers to do something.
I also hope that others will give you a chance to respond before this gets out of hand. Instead of letting a moment of frustration define us, let’s all take the high road. There’s enough negativity in the world, and I personally come to the openHAB community to get away from it.
@rpwong Don’t worry Russ, I didn’t meant we should rope volunteer maintainers and actually force them to apply some feature with a help of soldering iron =) But as a new user I actively search community forum for solutions and I often see other users asking questions and having issues with items or things, added with textual or UI config. Old users have issues when migrating from Oh2.5, new users see Oh2 recipes, apply them, then cannot find out how to edit their newly created items to add them to semantic model.
I personally got an issue with the very start to Oh while using RGroll’s example widget for OpenWheatherMap - there are two options how to create 667 needed items, by .items or by 667 clicks in UI, I’ve chosen file config and had to redo everything later to UI items to apply semantic model, tags and so on.
I think that those two approaches, UI and textual-based, have their own advantages and disadvantages, the first is better for fast changes of single item or fine tuning, the second is better for sharing solutions and initial setup, so we all have to use both of them, so we really need interaction between them.
Just FTR, I am openHABian maintainer but no core developer i.e. just a user like everybody else.
So even if I agreed to what @11194 wrote (which I do by no means even if I disregarded his wording),
I could not do anything about it other than to enhance the docs. Which is what I did while @11194 was busy texting his lack of respect.
This way my browser window just hanged up and never recovered. And in the end I decided to have just a 7-day forecast, as 14-days is too far from truth for my location and has no sense. And remember - I was totally new to Openhab, and this widget was a first try for me, as it was for many other users.
Here it is, a compromise between the two approaches.
I am not shure if that proposal will allow editing GUI created things/items/etc. via VS-Code, as you cannot edit the JSON-DB where those are stored while openHAB is running. This might need some core changes for the way those entities are stored internally which will introduce breaking changes….
Are they supposed to apply changes on-the-go? There could be a VScode shortcut for stopservice-apply-startservice.
Oh wait. We do edit JSON-DB when Oh is running, with UI, ain’t we? I hope REST-API could help to manage everything online.
Stopping openHAB and restarting will interrupt the connection to the LSP, so really a bad idea.
Yes, MainUI does this „on the fly“, but this needs to be implemented in VS-Code. Possible, yes, should be, easy to implement, I don‘t know.
Thanks for taking the time to respond. Deadpan sarcasm generally doesn’t translate well in written English, so your comment appeared to be an angry rant, not humour. When I see things going sideways (often due to language choices), I try to right the ship so that we can have productive conversations.