Christian-Me / node-red-contrib-homie-convention

Node-RED node for MQTT communication according the Homie Convention
Apache License 2.0
13 stars 2 forks source link

Node Validation fails with multiple devices / large broker content #5

Open xAPPO opened 4 years ago

xAPPO commented 4 years ago

Opened from main discussion thread...

Using a big homie tree with 10 devices and lots of nodes (~3000 topics) the MQTT Node-RED load fails, displaying only 6 devices and flags node validation failure on nearly every node. I have provided broker access to test against. This could well be my homie implementation as well as a lot of devices are rushed !

I tried to circumvent this by using homie/deviceName as the root topic (useful to support this device level selection I think). This mostly works but then it validation fails $state being absent at the node (not device) level which is somewhere it shouldn't be used in the spec. This is probably, I think because of my hierarchy shift with the root topic.

xAPPO commented 4 years ago

I have created a restricted access user on my broker that only sees two devices 'development' and 'homeo' in the homie tree so much smaller. This device has only 24 nodes (316 topics) and is the output of my about to be released (beta) Hubitat plugin so I want it to be right ! Having a validation tool is most useful ;-)

I am getting the device validation $state not specified errors still so I'm going to investigate some more as others would have reported this too - so it looks like it's me. So probably not triggered by the volume of devices/nodes.

@Christian-Me If you add a 2 on the end of your existing username and use the same password then you can access the reduced to two device tree.

Let me work on the topic integrity. My $nodes is still not quite right ..

Update: Working much better Christian - still a lot of devices where nodes are listed but no properties listed within them - from both mine (development) and Harrie's Homey (Homeo) implementation. I'll see if I can see what's different.

Gledholt commented 4 years ago

Just swung around and wow you've done a lot of work on this Christian - things seem so much better. All looks good but I'll have a good play and see what I find. You've already identified a couple of missing topics in my nodes which is great !

Christian-Me commented 4 years ago

Hi, nice to hear from you.

Yes I’m doing constantly some updates but my time is limited.

A bigger update on the homie node is in preparation adding a new node for handling status messages from $state, $stats to $fw and others.

The data can then feed into a nice table on the dashboard to keep an eye on all your devices:

image

Sorry I was not able to throw your mqtt broker on the homie node. Hope I can do it soon.

Greetings from Berlin.

Christian-Me commented 4 years ago

Hi, in case you have not be aware, I pushed a major update of the homie-convention node and a first beta of the remote-device-table flow ... perhaps you like it (and perhaps it solve some of your issue).

GledholtHall commented 4 years ago

I will check and update, appreciate the ongoing work on this

Christian-Me commented 4 years ago

@GledholtHall contact me if you have any question ... Really need input of users to get out of beta

Christian-Me commented 4 years ago

BTW most updates only happening on github. I whant to push these to npm only if they are fairly tested.

Christian-Me commented 3 years ago

Don't know if you are still interested:

I pushed a development branch. If interested you can give it a try. Currently I have around 2.500 Topics on my broker with 5 base Ids ... size should not be a problem.

Had it lying around quite a while doing other stuff like my own ESP based homie framework so it took a wile to understand all my own legacy code. All still alpha/beta, but I start rolling it out into my live system ... so should be "usable" with some bugs and sharp edges.

current status:

Any Inputs and ideas welcome :)

xAPPO commented 3 years ago

Yes - I'll take a look - will still be very useful to me

Really stupid Q but what is the easiest way to upgrade an NPM installed 0.19 version to the development release or to install the dev release in a n existing NodeRED Docker container ?

Christian-Me commented 3 years ago

Hi,

was just browsing to my github notifications and found your massage (and question) left open for a while, sorry.

I don't have any docker experience at all. You certainly know how to install a node from github ... so this will not help you out?

npm i Christian-Me/node-red-contrib-homie-convention#develop