Files
neuron/plugins/mqtt/mqtt.json
T
gc87 9d3b411627 fix(mqtt): setting free
* Add unit test for setting
* Set mqtt.json format field to optinal
2022-07-15 14:39:57 +08:00

156 lines
2.6 KiB
JSON

{
"client-id": {
"name": "client id",
"description": "Neuron MQTT client ID",
"type": "string",
"attribute": "required",
"default": "",
"valid": {
"length": 255
}
},
"upload-topic": {
"name": "upload topic",
"description": "User-defined upload topic",
"type": "string",
"attribute": "optional",
"default": "",
"valid": {
"length": 255
}
},
"heartbeat-topic": {
"name": "heartbeat topic",
"description": "User-defined heartbeat topic",
"type": "string",
"attribute": "optional",
"default": "",
"valid": {
"length": 255
}
},
"format": {
"name": "upload format",
"description": "Upload format on mqtt",
"attribute": "optional",
"type": "map",
"default": 0,
"valid": {
"map": [
{
"key": "format-values",
"value": 0
},
{
"key": "format-tags",
"value": 1
}
]
}
},
"ssl": {
"name": "ssl",
"description": "Enable SSL connection",
"attribute": "required",
"type": "bool",
"default": false,
"valid": {}
},
"host": {
"name": "host",
"description": "MQTT broker host",
"attribute": "required",
"type": "string",
"default": "broker.emqx.io",
"valid": {
"length": 255
}
},
"port": {
"name": "port",
"description": "MQTT broker port",
"attribute": "required",
"type": "int",
"default": 1883,
"valid": {
"min": 1024,
"max": 65535
}
},
"username": {
"name": "username",
"description": "User name",
"attribute": "optional",
"type": "string",
"default": "",
"valid": {
"length": 255
}
},
"password": {
"name": "password",
"description": "Password",
"attribute": "optional",
"type": "string",
"default": "",
"valid": {
"length":255
}
},
"ca": {
"name": "CA",
"description": "CA certificate file",
"attribute": "required",
"type": "file",
"condition": {
"field": "ssl",
"value": true
},
"default": "",
"valid": {
"length": 81960
}
},
"cert": {
"name": "client cert",
"description": "client x509 certificate file",
"attribute": "optional",
"type": "file",
"condition": {
"field": "ssl",
"value": true
},
"default": "",
"valid": {
"length": 81960
}
},
"key": {
"name": "client key",
"description": "client key file",
"attribute": "optional",
"type": "file",
"condition": {
"field": "ssl",
"value": true
},
"default": "",
"valid": {
"length": 81960
}
},
"keypass": {
"name": "keypass",
"description": "key password",
"attribute": "optional",
"type": "string",
"condition": {
"field": "ssl",
"value": true
},
"default": "",
"valid": {
"length": 256
}
}
}