I wanted to get your opinion on the usage of Node RED and MQTT. Recently I have been moving from integrating mosquitto with openhab to integrating with node-red.
What I mean with that is that instead of configuring the mqtt channel on the item in openhab, I only create the item in openhab. Then instead of updating the state of the item through openhab mqtt integration, i created a MQTT receiving node in Node-RED and use that to transform where needed (change node) and update the item state in openHAB.
The main benefit for me is that I dont need to mess around with java scripts to do my simple transformations and can handle these with the change node in Node-RED.
For example if my motion sensor sends an MQTT message with “occupancy:false”, I can easily use a change node in Node-RED with “if contains false, set payload to OFF” and send that payload to the item state for my motion sensor (Switch)