mirror of
https://github.com/Luzifer/mqtt2influx.git
synced 2024-12-20 09:31:23 +00:00
Log number of topics on connect
Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
parent
e7ae8ac75f
commit
4fb30ba2d8
1 changed files with 3 additions and 1 deletions
4
main.py
4
main.py
|
@ -29,7 +29,9 @@ class MQTT2InfluxDB():
|
|||
if result != mqtt.MQTT_ERR_SUCCESS:
|
||||
raise(Exception('MQTT subscribe failed: {}'.format(result)))
|
||||
|
||||
logging.info('MQTT connected and subscribed')
|
||||
logging.info('MQTT connected and subscribed to {n} topics'.format(
|
||||
n=len(topics),
|
||||
))
|
||||
|
||||
def on_message(self, client, userdata, msg):
|
||||
points = []
|
||||
|
|
Loading…
Reference in a new issue