summaryrefslogtreecommitdiffstats
path: root/monitoring
diff options
context:
space:
mode:
authorAashish Sharma <66050535+aaSharma14@users.noreply.github.com>2024-11-05 10:39:52 +0100
committerGitHub <noreply@github.com>2024-11-05 10:39:52 +0100
commit9eaff51b9da7c07e29fdc75ff1c75d663c242ae0 (patch)
tree9a53498338195dd04c93cb0e5a27edfe475255b8 /monitoring
parentMerge pull request #60017 from rhcs-dashboard/kcli-quick-install (diff)
parentmgr/dashboard: Add 'Browse Dashboards' button in multi-cluster and ceph-clust... (diff)
downloadceph-9eaff51b9da7c07e29fdc75ff1c75d663c242ae0.tar.xz
ceph-9eaff51b9da7c07e29fdc75ff1c75d663c242ae0.zip
Merge pull request #60100 from piyushagarwal1411/fix-68316-main
mgr/dashboard: Add 'Browse Dashboards' button in multi-cluster and ceph-cluster Grafana dashboards Reviewed-by: Aashish Sharma <aasharma@redhat.com>
Diffstat (limited to 'monitoring')
-rw-r--r--monitoring/ceph-mixin/dashboards/multi-cluster.libsonnet15
-rw-r--r--monitoring/ceph-mixin/dashboards/utils.libsonnet23
-rw-r--r--monitoring/ceph-mixin/dashboards_out/ceph-cluster.json15
-rw-r--r--monitoring/ceph-mixin/dashboards_out/multi-cluster-overview.json15
4 files changed, 66 insertions, 2 deletions
diff --git a/monitoring/ceph-mixin/dashboards/multi-cluster.libsonnet b/monitoring/ceph-mixin/dashboards/multi-cluster.libsonnet
index 8185ebb253b..6b070319202 100644
--- a/monitoring/ceph-mixin/dashboards/multi-cluster.libsonnet
+++ b/monitoring/ceph-mixin/dashboards/multi-cluster.libsonnet
@@ -43,6 +43,21 @@ local g = import 'grafonnet/grafana.libsonnet';
),
)
+ .addLinks([
+ $.addLinkSchema(
+ asDropdown=true,
+ icon='external link',
+ includeVars=true,
+ keepTime=true,
+ tags=[],
+ targetBlank=false,
+ title='Browse Dashboards',
+ tooltip='',
+ type='dashboards',
+ url=''
+ ),
+ ])
+
.addPanels([
$.addRowSchema(false, true, 'Clusters') + { gridPos: { x: 0, y: 1, w: 24, h: 1 } },
$.addStatPanel(
diff --git a/monitoring/ceph-mixin/dashboards/utils.libsonnet b/monitoring/ceph-mixin/dashboards/utils.libsonnet
index 333a444dda1..50fa0027f28 100644
--- a/monitoring/ceph-mixin/dashboards/utils.libsonnet
+++ b/monitoring/ceph-mixin/dashboards/utils.libsonnet
@@ -133,6 +133,29 @@ local timeSeries = import 'timeseries_panel.libsonnet';
allValues=allValues,
current=current),
+ addLinkSchema(asDropdown,
+ icon,
+ includeVars,
+ keepTime,
+ tags,
+ targetBlank,
+ title,
+ tooltip,
+ type,
+ url)::
+ {
+ asDropdown: asDropdown,
+ icon: icon,
+ includeVars: includeVars,
+ keepTime: keepTime,
+ tags: tags,
+ targetBlank: targetBlank,
+ title: title,
+ tooltip: tooltip,
+ type: type,
+ url: url,
+ },
+
addAnnotationSchema(builtIn,
datasource,
enable,
diff --git a/monitoring/ceph-mixin/dashboards_out/ceph-cluster.json b/monitoring/ceph-mixin/dashboards_out/ceph-cluster.json
index 1fd7821a6b6..0b5abd73d90 100644
--- a/monitoring/ceph-mixin/dashboards_out/ceph-cluster.json
+++ b/monitoring/ceph-mixin/dashboards_out/ceph-cluster.json
@@ -35,7 +35,20 @@
"hideControls": false,
"id": null,
"iteration": 1525415495309,
- "links": [],
+ "links": [
+ {
+ "asDropdown": true,
+ "icon": "external link",
+ "includeVars": true,
+ "keepTime": true,
+ "tags": [],
+ "targetBlank": false,
+ "title": "Browse Dashboards",
+ "tooltip": "",
+ "type": "dashboards",
+ "url": ""
+ }
+ ],
"panels": [
{
"cacheTimeout": null,
diff --git a/monitoring/ceph-mixin/dashboards_out/multi-cluster-overview.json b/monitoring/ceph-mixin/dashboards_out/multi-cluster-overview.json
index 25648cc0abb..b9ccc453ac8 100644
--- a/monitoring/ceph-mixin/dashboards_out/multi-cluster-overview.json
+++ b/monitoring/ceph-mixin/dashboards_out/multi-cluster-overview.json
@@ -22,7 +22,20 @@
"graphTooltip": 0,
"hideControls": false,
"id": null,
- "links": [ ],
+ "links": [
+ {
+ "asDropdown": true,
+ "icon": "external link",
+ "includeVars": true,
+ "keepTime": true,
+ "tags": [],
+ "targetBlank": false,
+ "title": "Browse Dashboards",
+ "tooltip": "",
+ "type": "dashboards",
+ "url": ""
+ }
+ ],
"panels": [
{
"collapse": false,