mirror of https://github.com/nicolargo/glances
chg: exports (influxdb) - log warning message if export fails
parent
48103f167e
commit
0e1d462c69
|
@ -156,7 +156,7 @@ class Export(GlancesExport):
|
||||||
try:
|
try:
|
||||||
self.client.write_points(self._normalize(name, columns, points), time_precision="s")
|
self.client.write_points(self._normalize(name, columns, points), time_precision="s")
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
# Log level set to debug instead of error (see: issue #1561)
|
# Log level set to warning instead of error (see: issue #1561)
|
||||||
logger.debug(f"Cannot export {name} stats to InfluxDB ({e})")
|
logger.warning(f"Cannot export {name} stats to InfluxDB ({e})")
|
||||||
else:
|
else:
|
||||||
logger.debug(f"Export {name} stats to InfluxDB")
|
logger.debug(f"Export {name} stats to InfluxDB")
|
||||||
|
|
|
@ -164,7 +164,7 @@ class Export(GlancesExport):
|
||||||
try:
|
try:
|
||||||
self.client.write(self.bucket, self.org, self._normalize(name, columns, points), time_precision="s")
|
self.client.write(self.bucket, self.org, self._normalize(name, columns, points), time_precision="s")
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
# Log level set to debug instead of error (see: issue #1561)
|
# Log level set to warning instead of error (see: issue #1561)
|
||||||
logger.debug(f"Cannot export {name} stats to InfluxDB ({e})")
|
logger.warning(f"Cannot export {name} stats to InfluxDB ({e})")
|
||||||
else:
|
else:
|
||||||
logger.debug(f"Export {name} stats to InfluxDB")
|
logger.debug(f"Export {name} stats to InfluxDB")
|
||||||
|
|
Loading…
Reference in New Issue