[Bug][Grafana] Redundant root grafana-irm.json causes dashboard UID collisions in MySQL and phantom dashboard in PostgreSQL
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 1/5
- 見積もり時間
- 1時間未満
- 初心者へのやさしさ
- 95/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- docker, grafana
調査の方向性
まず grafana/dashboards/grafana-irm.json を方言ごとのダッシュボードと併せて調査し、次に grafana/Dockerfile と entrypoint.sh を確認して、provisioning パスがどのようにコピーおよびフィルタリングされるかを確認します。冗長なルートのダッシュボードファイルを削除し、各 DATABASE_TYPE について MySQL または PostgreSQL のダッシュボードだけが残ることを検証します。ドキュメント化された Docker の build および startup チェックでは、UID の衝突や phantom dashboard がないことが示されるはずです。
索引モデルが issue の本文から書いたものです。
説明
Search before asking
- I had searched in the issues and found no similar issues.
What happened
Following the merge of PR #9160, the new Grafana IRM dashboard was added to dialect-specific directories (grafana/dashboards/mysql/grafana-irm.json and grafana/dashboards/postgresql/grafana-irm.json), but a duplicate file was also left at the root level in grafana/dashboards/grafana-irm.json.
In the container build (grafana/Dockerfile), the entire dashboards directory is copied into /etc/grafana/dashboards.
-
MySQL mode (
DATABASE_TYPE=mysql):entrypoint.shremoves/etc/grafana/dashboards/postgresql.- Both
/etc/grafana/dashboards/grafana-irm.jsonand/etc/grafana/dashboards/mysql/grafana-irm.jsonremain on disk with the identical UID:"uid": "grafana-irm-dashboard". - Grafana's file provider provisions dashboards recursively, encountering both files and throwing a duplicate UID collision:
logger=provisioning.dashboard type=file name="My Dashboard" level=error msg="failed to load dashboard from file" file=/etc/grafana/dashboards/grafana-irm.json error="dashboard with uid 'grafana-irm-dashboard' already exists"
-
PostgreSQL mode (
DATABASE_TYPE=postgresql):entrypoint.shremoves/etc/grafana/dashboards/mysql.- Both
/etc/grafana/dashboards/postgresql/grafana-irm.json(UIDgrafana-irm-dashboard-pg) and the stray root/etc/grafana/dashboards/grafana-irm.json(UIDgrafana-irm-dashboard) are loaded under the same title"Grafana IRM". - The root dashboard attempts to query the MySQL datasource (
devlake-mysql-api), which does not exist in PostgreSQL mode, resulting in a duplicate broken dashboard in the Grafana UI.
What do you expect to happen
Each dashboard file should only exist within its designated dialect folder (grafana/dashboards/mysql/ or grafana/dashboards/postgresql/). No duplicate files should reside in the root grafana/dashboards/ directory so that provisioning loads each dashboard exactly once without UID conflicts or cross-dialect query errors.
How to reproduce
- Inspect the repository at
grafana/dashboards/or build and run the Grafana container:docker build -t devlake-dashboard:test grafana/ docker run --rm -e DATABASE_TYPE=mysql devlake-dashboard:test - Verify that both
/etc/grafana/dashboards/grafana-irm.jsonand/etc/grafana/dashboards/mysql/grafana-irm.jsonexist. - Observe the Grafana startup logs indicating a duplicate dashboard UID error for
grafana-irm-dashboard. - Alternatively, run with
-e DATABASE_TYPE=postgresqland check the dashboard list in the Grafana UI; observe two "Grafana IRM" dashboards, with the root one failing due to missingdevlake-mysql-api.
Anything else
- Affected file to be removed:
grafana/dashboards/grafana-irm.json - Active dialect dashboards:
grafana/dashboards/mysql/grafana-irm.json(MySQL datasource)grafana/dashboards/postgresql/grafana-irm.json(PostgreSQL datasource)
grafana/dashboards/grafana-irm.jsonandgrafana/dashboards/mysql/grafana-irm.jsonare byte-for-byte identical; removing the root file cleanly eliminates the collision without impacting MySQL or PostgreSQL dashboard provisioning.
Version
b0a758996 (commit on main following PR #9160 / #9173)
Are you willing to submit PR?
- Yes I am willing to submit a PR!
Code of Conduct
- I agree to follow this project's Code of Conduct
- 主要言語
- Go
- スター
- 3.1k
- フォーク
- 812
- 平均マージ
- 2日 8時間
- マージ済み PR(30日)
- 50
環境構築
このプロジェクトの環境構築ファイルはまだ確認していません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
apache/devlake のほかの issue
-
難易度 3/5 1〜2日 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信
-
[Bug][jenkins] Incremental collection skips the stages of builds that finish after the next syncオープン
難易度 3/5 1〜2日 初心者へのやさしさ 76/100
apache/devlake#9177 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
type/bug
難易度 4/5 3〜5日 初心者へのやさしさ 68/100
apache/devlake#9170 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
[Feature][Plugins] Add YouTrack plugin対応中かも @tpam28 が 3 日前に担当しました。 オープン
難易度 5/5 1週間以上 初心者へのやさしさ 32/100
apache/devlake#9168 · コメント 1 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
[Bug][Jira/DORA] Extra JQL does not isolate projects sharing the same Jira board対応中かも @veetmoradiya3628 が 8 日前に担当しました。 オープン
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
apache/devlake#9151 · コメント 2 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
似ている issue
-
automation models
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
txn2/mcp-data-platform#1984 ·
メンテナーはふだん 1 日以内に返信
-
agentic-workflows
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
メンテナーはふだん 1 日以内に返信
-
kind/docs prio/P2
難易度 1/5 1時間未満 初心者へのやさしさ 95/100
agent-substrate/substrate#1986 ·
メンテナーはふだん 1 日以内に返信