]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
mgr/influx: Only fetch the current time once when gathering data 22414/head
authorWido den Hollander <wido@42on.com>
Wed, 31 Jan 2018 13:43:54 +0000 (14:43 +0100)
committerWido den Hollander <wido@42on.com>
Wed, 6 Jun 2018 13:51:00 +0000 (15:51 +0200)
commitbcef1f8866a03dc74dc85030d4a24432c5765918
treed1aa6767e4d133006dad75ae67fb313338bbd2e7
parent0762c0f8be37e4f36fef58a5fd65ae90567c9d9b
mgr/influx: Only fetch the current time once when gathering data

By fetching the current time once and storing it into a variable
we save a lot of system calls. On large clusters this can be a lot
of system calls.

In addition we also make sure that all points gathered in the same
loop/run have exactly the same timestamp.

Otherwise there will be a difference in time between the items in
InfluxDB which then causes problems when creating graphs with for
example Grafana.

Signed-off-by: Wido den Hollander <wido@42on.com>
(cherry picked from commit 0857d3bcd4175f39582376fb9980cf3f66fa09ce)
src/pybind/mgr/influx/module.py