From 15174bac899bd2deb9cebc910984de66a6101d78 Mon Sep 17 00:00:00 2001 From: Yaarit Hatuka Date: Mon, 27 Mar 2023 22:51:51 +0000 Subject: [PATCH] mgr/telemetry: add leaderboard description and documentation Users who are opted-in to telemetry can also opt-in to participating in a leaderboard in the telemetry public dashboards (https://telemetry-public.ceph.com/). Users can also add a description of the cluster to publicly appear in the leaderboard. Signed-off-by: Yaarit Hatuka (cherry picked from commit d51947fe8a9bb514e5a6309551c10224efdcfa0d) --- doc/mgr/telemetry.rst | 17 +++++++++++++++++ src/pybind/mgr/telemetry/module.py | 5 +++++ 2 files changed, 22 insertions(+) diff --git a/doc/mgr/telemetry.rst b/doc/mgr/telemetry.rst index 388353b84adc..72ec61dada86 100644 --- a/doc/mgr/telemetry.rst +++ b/doc/mgr/telemetry.rst @@ -269,3 +269,20 @@ completely optional, and disabled by default.:: ceph config set mgr mgr/telemetry/description 'My first Ceph cluster' ceph config set mgr mgr/telemetry/channel_ident true +Leaderboard +----------- + +Users who are interested in participating in a leaderboard in the `public +dashboards `_ can do so with:: + + ceph config set mgr mgr/telemetry/leaderboard true + +The leaderboard displays basic information about the cluster, like total +storage capacity, number of OSDs, etc. A description of the cluster can be +added with:: + + ceph config set mgr mgr/telemetry/leaderboard_description 'Ceph cluster for Computational Biology at the University of XYZ' + +In case the 'ident' channel is enabled, its details will not be displayed in +the leaderboard. + diff --git a/src/pybind/mgr/telemetry/module.py b/src/pybind/mgr/telemetry/module.py index 2626679113bb..74e289461d2e 100644 --- a/src/pybind/mgr/telemetry/module.py +++ b/src/pybind/mgr/telemetry/module.py @@ -198,6 +198,9 @@ class Module(MgrModule): Option(name='leaderboard', type='bool', default=False), + Option(name='leaderboard_description', + type='str', + default=None), Option(name='description', type='str', default=None), @@ -261,6 +264,7 @@ class Module(MgrModule): self.enabled = False self.last_opt_revision = 0 self.leaderboard = '' + self.leaderboard_description = '' self.interval = 0 self.proxy = '' self.channel_basic = True @@ -980,6 +984,7 @@ class Module(MgrModule): channels = self.get_active_channels() report = { 'leaderboard': self.leaderboard, + 'leaderboard_description': self.leaderboard_description, 'report_version': 1, 'report_timestamp': datetime.utcnow().isoformat(), 'report_id': self.report_id, -- 2.47.3