mqtt-to-influxdb

flow to pass data from mqtt subscriber to a influxdb database

[{"id":"b716fdc48724e610","type":"tab","label":"Flow 1","disabled":false,"info":""},{"id":"d50d0c9f.31e858","type":"tls-config","name":"","cert":"","key":"","ca":"","certname":"","keyname":"","caname":"","servername":"","verifyservercert":false},{"id":"bc4ab5cb2a050021","type":"influxdb","hostname":"127.0.0.1","port":"8086","protocol":"http","database":"test","name":"test","usetls":true,"tls":"d50d0c9f.31e858","influxdbVersion":"2.0","url":"http://localhost:8086","rejectUnauthorized":false},{"id":"562ec1085cc9dbf1","type":"mqtt-broker","name":"","broker":"10.10.10.60","port":"1883","clientid":"","usetls":false,"protocolVersion":"4","keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","birthMsg":{},"closeTopic":"","closeQos":"0","closePayload":"","closeMsg":{},"willTopic":"","willQos":"0","willPayload":"","willMsg":{},"sessionExpiry":""},{"id":"0e17644c4b3628b4","type":"influxdb out","z":"b716fdc48724e610","influxdb":"bc4ab5cb2a050021","name":"","measurement":"test","precision":"","retentionPolicy":"","database":"","retentionPolicyV18Flux":"","org":"Industrial Shields","bucket":"test","x":680,"y":80,"wires":[]},{"id":"0c42600975da386c","type":"debug","z":"b716fdc48724e610","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":670,"y":120,"wires":[]},{"id":"65e33f58d20fee33","type":"mqtt in","z":"b716fdc48724e610","name":"","topic":"/industrial/shields","qos":"2","datatype":"auto","broker":"562ec1085cc9dbf1","nl":false,"rap":true,"rh":0,"x":160,"y":80,"wires":[["69f73915a01982c3","1ba5715c13107a23"]]},{"id":"69f73915a01982c3","type":"change","z":"b716fdc48724e610","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"$number(payload)\t","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":400,"y":80,"wires":[["0e17644c4b3628b4","0c42600975da386c"]]},{"id":"1ba5715c13107a23","type":"debug","z":"b716fdc48724e610","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":390,"y":120,"wires":[]}]

Flow Info

Created 3 years, 2 months ago
Rating: not yet rated

Owner

Actions

Rate:

Node Types

Core
  • change (x1)
  • debug (x2)
  • mqtt in (x1)
  • mqtt-broker (x1)
  • tls-config (x1)
Other
  • influxdb (x1)
  • influxdb out (x1)
  • tab (x1)

Tags

Copy this flow JSON to your clipboard and then import into Node-RED using the Import From > Clipboard (Ctrl-I) menu option