MQTT Consumer fails with invalid connection_timeout value
telegraf stops working after the last update, in the log files i receive the follow message.
2017-09-29T21:17:00Z E! Service for input inputs.mqtt_consumer failed to start, exiting MQTT Consumer, invalid connection_timeout value: {0} 2017-09-29T21:19:32Z E! Service for input inputs.mqtt_consumer failed to start, exiting MQTT Consumer, invalid connection_timeout value: {30000000000} 2017-09-29T21:24:05Z E! Service for input inputs.mqtt_consumer failed to start, exiting MQTT Consumer, invalid connection_timeout value: {30000000000}
The first time I did not configured the connection timeout the second time I did but I guess its not parsed right
my config is
[[inputs.mqtt_consumer]]
servers = ["localhost:1883"]
# ## MQTT QoS, must be 0, 1, or 2
qos = 0
connection_timeout = 30
When I change the connection_timeout = 30 to connection_timeout =1 telefgraf will start up
I think this should actually be a string duration, can you test with connection_timeout = "30s"?
tested it with 30s and that does seam to do the trick, so only the documentation at https://github.com/influxdata/telegraf/blob/master/plugins/inputs/mqtt_consumer/README.md should be updated to reflect that
I will correct the documentation and also set a default timeout if it is not specified.