From: Yaarit Hatuka Date: Fri, 7 Feb 2020 15:04:50 +0000 (-0500) Subject: mgr/telemetry: add 'last_upload' to status X-Git-Tag: v15.1.1~390^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=3a25c912a702c7ec93002a105217a7ff80a67dc9;p=ceph.git mgr/telemetry: add 'last_upload' to status 'ceph telemetry status' now shows the last sent report date. Fixes: https://tracker.ceph.com/issues/44040 Signed-off-by: Yaarit Hatuka --- diff --git a/src/pybind/mgr/telemetry/module.py b/src/pybind/mgr/telemetry/module.py index e519bd7530e..d02a62a5651 100644 --- a/src/pybind/mgr/telemetry/module.py +++ b/src/pybind/mgr/telemetry/module.py @@ -742,6 +742,7 @@ class Module(MgrModule): r = {} for opt in self.MODULE_OPTIONS: r[opt['name']] = getattr(self, opt['name']) + r['last_upload'] = time.ctime(self.last_upload) if self.last_upload else self.last_upload return 0, json.dumps(r, indent=4, sort_keys=True), '' elif command['prefix'] == 'telemetry on': if command.get('license') != LICENSE: