This is an automated email from the ASF dual-hosted git repository.

abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git


The following commit(s) were added to refs/heads/main by this push:
     new 3e8929f45 fix: update jenkins and weekly bug retro dashboard (#3810)
3e8929f45 is described below

commit 3e8929f457075379753d0f7d83bf5d54cdc59102
Author: Louis.z <[email protected]>
AuthorDate: Thu Dec 1 11:43:59 2022 +0800

    fix: update jenkins and weekly bug retro dashboard (#3810)
    
    Co-authored-by: Startrekzky <[email protected]>
---
 grafana/dashboards/Jenkins.json        |  86 ++++++++++++----
 grafana/dashboards/WeeklyBugRetro.json | 180 +++++++--------------------------
 2 files changed, 105 insertions(+), 161 deletions(-)

diff --git a/grafana/dashboards/Jenkins.json b/grafana/dashboards/Jenkins.json
index 8de9c3333..637ed9cb6 100644
--- a/grafana/dashboards/Jenkins.json
+++ b/grafana/dashboards/Jenkins.json
@@ -15,8 +15,8 @@
   "editable": true,
   "gnetId": null,
   "graphTooltip": 0,
-  "id": 12,
-  "iteration": 1665485848500,
+  "id": 20,
+  "iteration": 1669388827168,
   "links": [],
   "panels": [
     {
@@ -29,7 +29,7 @@
       },
       "id": 58,
       "options": {
-        "content": "- Use Cases: This dashboard shows the basic CI/CD metrics 
from Jenkins.\n- Data Source Required: Jenkins",
+        "content": "- Use Cases: This dashboard shows the basic CI/CD metrics 
from Jenkins, such as [Build 
Count](https://devlake.apache.org/docs/Metrics/BuildCount), [Build 
Duration](https://devlake.apache.org/docs/Metrics/BuildDuration) and [Build 
Success Rate](https://devlake.apache.org/docs/Metrics/BuildSuccessRate).\n- 
Data Source Required: Jenkins",
         "mode": "markdown"
       },
       "pluginVersion": "8.0.6",
@@ -85,11 +85,11 @@
       "pluginVersion": "8.0.6",
       "targets": [
         {
-          "format": "time_series",
+          "format": "table",
           "group": [],
           "metricColumn": "none",
           "rawQuery": true,
-          "rawSql": "SELECT\n  now() AS time,\n  count(*)\nFROM \n  
cicd_pipelines p\nWHERE\n  $__timeFilter(p.created_date)\n  and p.id like 
\"%jenkins%\"\n  and p.name in ($job_id)\nORDER BY 1",
+          "rawSql": "SELECT\n  count(*)\nFROM \n  cicd_pipelines\nWHERE\n  
$__timeFilter(finished_date)\n  and result = 'SUCCESS'\n  and id like 
\"%jenkins%\"\n  and name in ($job_id)\n  -- the following condition will 
remove the month with incomplete data\n  and finished_date >= 
DATE_ADD(DATE_ADD($__timeFrom(), INTERVAL -DAY($__timeFrom())+1 DAY), INTERVAL 
+1 MONTH)",
           "refId": "A",
           "select": [
             [
@@ -115,7 +115,7 @@
       ],
       "timeFrom": null,
       "timeShift": null,
-      "title": "1. Total Number of Builds [Selected Time Range]",
+      "title": "1. Total Number of Successful Builds [Selected Time Range]",
       "type": "stat"
     },
     {
@@ -164,11 +164,11 @@
       "pluginVersion": "8.0.6",
       "targets": [
         {
-          "format": "time_series",
+          "format": "table",
           "group": [],
           "metricColumn": "none",
           "rawQuery": true,
-          "rawSql": "SELECT\n  now() AS time,\n  1.0 * count(case when 
p.result = 'SUCCESS' then 1 else null end)/count(*)\nFROM cicd_pipelines 
p\nWHERE\n  $__timeFilter(p.created_date)\n  and p.id like \"%jenkins%\"\n  and 
p.name in ($job_id)\nORDER BY 1",
+          "rawSql": "SELECT\n  1.0 * count(case when result = 'SUCCESS' then 1 
else null end)/count(*)\nFROM cicd_pipelines\nWHERE\n  
$__timeFilter(finished_date)\n  and id like \"%jenkins%\"\n  and name in 
($job_id)\n  -- the following condition will remove the month with incomplete 
data\n  and finished_date >= DATE_ADD(DATE_ADD($__timeFrom(), INTERVAL 
-DAY($__timeFrom())+1 DAY), INTERVAL +1 MONTH)",
           "refId": "A",
           "select": [
             [
@@ -200,7 +200,7 @@
     {
       "cacheTimeout": null,
       "datasource": "mysql",
-      "description": "The percentage of successful, failed, and aborted 
builds.",
+      "description": "",
       "fieldConfig": {
         "defaults": {
           "color": {
@@ -225,7 +225,8 @@
               "options": {
                 "mode": "exclude",
                 "names": [
-                  "build_count"
+                  "build_count",
+                  "ABORT"
                 ],
                 "prefix": "All except:",
                 "readOnly": true
@@ -241,6 +242,51 @@
                 }
               }
             ]
+          },
+          {
+            "matcher": {
+              "id": "byName",
+              "options": "SUCCESS"
+            },
+            "properties": [
+              {
+                "id": "color",
+                "value": {
+                  "fixedColor": "green",
+                  "mode": "fixed"
+                }
+              }
+            ]
+          },
+          {
+            "matcher": {
+              "id": "byName",
+              "options": "FAILURE"
+            },
+            "properties": [
+              {
+                "id": "color",
+                "value": {
+                  "fixedColor": "red",
+                  "mode": "fixed"
+                }
+              }
+            ]
+          },
+          {
+            "matcher": {
+              "id": "byName",
+              "options": "ABORT"
+            },
+            "properties": [
+              {
+                "id": "color",
+                "value": {
+                  "fixedColor": "rgba(205, 204, 206, 1)",
+                  "mode": "fixed"
+                }
+              }
+            ]
           }
         ]
       },
@@ -286,7 +332,7 @@
           "group": [],
           "metricColumn": "none",
           "rawQuery": true,
-          "rawSql": "SELECT\n  now() AS time,\n  p.result,\n  count(*) as 
build_count\nFROM cicd_pipelines p\nWHERE\n  $__timeFilter(p.created_date)\n  
and p.id like \"%jenkins%\"\n  and p.name in ($job_id)\nGROUP BY 1,2\nORDER BY 
1",
+          "rawSql": "SELECT\n  result,\n  count(*) as build_count\nFROM 
cicd_pipelines\nWHERE\n  $__timeFilter(finished_date)\n  and id like 
\"%jenkins%\"\n  and name in ($job_id)\n  -- the following condition will 
remove the month with incomplete data\n  and finished_date >= 
DATE_ADD(DATE_ADD($__timeFrom(), INTERVAL -DAY($__timeFrom())+1 DAY), INTERVAL 
+1 MONTH)\nGROUP BY 1\nORDER BY 2 desc",
           "refId": "A",
           "select": [
             [
@@ -359,11 +405,11 @@
       "pluginVersion": "8.0.6",
       "targets": [
         {
-          "format": "time_series",
+          "format": "table",
           "group": [],
           "metricColumn": "none",
           "rawQuery": true,
-          "rawSql": "SELECT\n  now() AS time,\n  avg(p.duration_sec/60) as 
duration_in_minute\nFROM cicd_pipelines p\nWHERE\n  
$__timeFilter(p.created_date)\n  and p.id like \"%jenkins%\"\n  and p.name in 
($job_id)\nORDER BY 1",
+          "rawSql": "SELECT\n  avg(duration_sec/60) as 
duration_in_minutes\nFROM cicd_pipelines\nWHERE\n  
$__timeFilter(finished_date)\n  and id like \"%jenkins%\"\n  and name in 
($job_id)\n  -- the following condition will remove the month with incomplete 
data\n  and finished_date >= DATE_ADD(DATE_ADD($__timeFrom(), INTERVAL 
-DAY($__timeFrom())+1 DAY), INTERVAL +1 MONTH)",
           "refId": "A",
           "select": [
             [
@@ -462,7 +508,7 @@
           "hide": false,
           "metricColumn": "none",
           "rawQuery": true,
-          "rawSql": "with _builds as(\n  SELECT\n    
DATE_ADD(date(p.created_date), INTERVAL -DAYOFMONTH(date(p.created_date))+1 
DAY) as time,\n    count(*) as build_count\n  FROM cicd_pipelines p\nWHERE\n  
$__timeFilter(p.created_date)\n  and p.id like \"%jenkins%\"\n  and p.name in 
($job_id)\n  group by 1\n)\n\nSELECT \n  date_format(time,'%M %Y') as month,\n  
build_count as \"Build Count\"\nFROM _builds\nORDER BY time\n",
+          "rawSql": "WITH _builds as(\n  SELECT\n    
DATE_ADD(date(finished_date), INTERVAL -DAYOFMONTH(date(finished_date))+1 DAY) 
as time,\n    count(*) as build_count\n  FROM cicd_pipelines\n  WHERE\n    
$__timeFilter(finished_date)\n    and result = 'SUCCESS'\n    and id like 
\"%jenkins%\"\n    and name in ($job_id)\n    -- the following condition will 
remove the month with incomplete data\n    and finished_date >= 
DATE_ADD(DATE_ADD($__timeFrom(), INTERVAL -DAY($__timeFrom())+1 DAY), [...]
           "refId": "A",
           "select": [
             [
@@ -486,7 +532,7 @@
           ]
         }
       ],
-      "title": "1.1 Total Number of Builds [Each Month]",
+      "title": "1.1 Total Number of Successful Builds [Each Month]",
       "type": "barchart"
     },
     {
@@ -578,7 +624,7 @@
           "group": [],
           "metricColumn": "none",
           "rawQuery": true,
-          "rawSql": "with _build_success_rate as(\r\n  SELECT\r\n    
DATE_ADD(date(p.created_date), INTERVAL -DAYOFMONTH(date(p.created_date))+1 
DAY) as time,\r\n    p.result as result\r\n  FROM\r\n    cicd_pipelines 
p\r\nWHERE\r\n  $__timeFilter(p.created_date)\r\n  and p.id like 
\"%jenkins%\"\r\n  and p.name in ($job_id)\r\n)\r\n\r\nSELECT \r\n  
date_format(time,'%M %Y') as month,\r\n  1.0 * sum(case when result = 'SUCCESS' 
then 1 else 0 end)/ count(*) as \"Build Success Rate\"\r\nFROM [...]
+          "rawSql": "WITH _build_success_rate as(\r\n  SELECT\r\n    
DATE_ADD(date(finished_date), INTERVAL -DAYOFMONTH(date(finished_date))+1 DAY) 
as time,\r\n    result\r\n  FROM\r\n    cicd_pipelines\r\n  WHERE\r\n    
$__timeFilter(finished_date)\r\n    and id like \"%jenkins%\"\r\n    and name 
in ($job_id)\r\n    -- the following condition will remove the month with 
incomplete data\r\n    and finished_date >= DATE_ADD(DATE_ADD($__timeFrom(), 
INTERVAL -DAY($__timeFrom())+1 DAY), INTER [...]
           "refId": "A",
           "select": [
             [
@@ -718,7 +764,7 @@
           "hide": false,
           "metricColumn": "none",
           "rawQuery": true,
-          "rawSql": "SELECT\n  DATE_ADD(date(p.created_date), INTERVAL 
-DAYOFMONTH(date(p.created_date))+1 DAY) as time,\n  count(distinct case when 
p.result = 'SUCCESS' then p.id else null end) as successful_build_count,\n  
count(distinct case when p.result != 'SUCCESS' then p.id else null end) as 
failed_build_count\nFROM cicd_pipelines p\nWHERE\n  
$__timeFilter(p.created_date)\n  and p.id like \"%jenkins%\"\n  and p.name in 
($job_id)\ngroup by 1",
+          "rawSql": "SELECT\n  DATE_ADD(date(finished_date), INTERVAL 
-DAYOFMONTH(date(finished_date))+1 DAY) as time,\n  count(distinct case when 
result = 'SUCCESS' then id else null end) as successful_build_count,\n  
count(distinct case when result != 'SUCCESS' then id else null end) as 
failed_build_count\nFROM cicd_pipelines\nWHERE\n  
$__timeFilter(finished_date)\n  and id like \"%jenkins%\"\n  and name in 
($job_id)\n  -- the following condition will remove the month with incomplete d 
[...]
           "refId": "A",
           "select": [
             [
@@ -785,7 +831,7 @@
           {
             "matcher": {
               "id": "byName",
-              "options": "duration_in_minute"
+              "options": "mean_duration_minutes"
             },
             "properties": [
               {
@@ -831,7 +877,7 @@
           "hide": false,
           "metricColumn": "none",
           "rawQuery": true,
-          "rawSql": "with _builds as(\n  SELECT\n    
DATE_ADD(date(p.created_date), INTERVAL -DAYOFMONTH(date(p.created_date))+1 
DAY) as time,\n    avg(p.duration_sec) as duration\n  FROM \n    cicd_pipelines 
p\nWHERE\n  $__timeFilter(p.created_date)\n  and p.id like \"%jenkins%\"\n  and 
p.name in ($job_id)\n  group by 1\n)\n\nSELECT \n  date_format(time,'%M %Y') as 
month,\n  duration/60 as duration_in_minute\nFROM _builds\nORDER BY time\n",
+          "rawSql": "WITH _builds as(\n  SELECT\n    
DATE_ADD(date(finished_date), INTERVAL -DAYOFMONTH(date(finished_date))+1 DAY) 
as time,\n    avg(duration_sec) as mean_duration_sec\n  FROM \n    
cicd_pipelines\n  WHERE\n    $__timeFilter(finished_date)\n    and id like 
\"%jenkins%\"\n    and name in ($job_id)\n    -- the following condition will 
remove the month with incomplete data\n    and finished_date >= 
DATE_ADD(DATE_ADD($__timeFrom(), INTERVAL -DAY($__timeFrom())+1 DAY), INTERV 
[...]
           "refId": "A",
           "select": [
             [
@@ -925,5 +971,5 @@
   "timezone": "",
   "title": "Jenkins",
   "uid": "W8AiDFQnk",
-  "version": 53
+  "version": 13
 }
\ No newline at end of file
diff --git a/grafana/dashboards/WeeklyBugRetro.json 
b/grafana/dashboards/WeeklyBugRetro.json
index 7460c1df6..8cc447bfb 100644
--- a/grafana/dashboards/WeeklyBugRetro.json
+++ b/grafana/dashboards/WeeklyBugRetro.json
@@ -15,8 +15,8 @@
   "editable": true,
   "gnetId": null,
   "graphTooltip": 0,
-  "id": 19,
-  "iteration": 1668508842251,
+  "id": 13,
+  "iteration": 1669391436348,
   "links": [],
   "panels": [
     {
@@ -29,7 +29,7 @@
       },
       "id": 28,
       "options": {
-        "content": "- Use Cases: This dashboard can be used to track bugs.\n- 
Data Source Required: GitHub 
([transformation](https://devlake.apache.org/docs/UserManuals/ConfigUI/GitHub#step-3---adding-transformation-rules-optional)
 required) or Jira 
([transformation](https://devlake.apache.org/docs/UserManuals/ConfigUI/Jira#step-3---adding-transformation-rules-optional)
 required). Transformation is the configuration for you to tell DevLake what is 
a bug.",
+        "content": "- Use Cases: This dashboard can be used to track bugs with 
metrics such as [Bug Age](https://devlake.apache.org/docs/Metrics/BugAge).\n- 
Data Source Required: GitHub 
([transformation](https://devlake.apache.org/docs/UserManuals/ConfigUI/GitHub#step-3---adding-transformation-rules-optional)
 required) or Jira 
([transformation](https://devlake.apache.org/docs/UserManuals/ConfigUI/Jira#step-3---adding-transformation-rules-optional)
 required). Transformation is the configu [...]
         "mode": "markdown"
       },
       "pluginVersion": "8.0.6",
@@ -96,7 +96,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select\n  count(*)\nfrom\n  lake.issues as i\n  join 
lake.board_issues bi on i.id = bi.issue_id\n  join boards b on bi.board_id = 
b.id\nwhere\n  i.type in ($issue_type)\n  and date(i.created_date) BETWEEN 
curdate() - INTERVAL WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL 
WEEKDAY(curdate())+1 DAY\n  and b.id in ($repo_id)",
+          "rawSql": "select\n  count(*)\nfrom\n  lake.issues as i\n  join 
lake.board_issues bi on i.id = bi.issue_id\n  join boards b on bi.board_id = 
b.id\nwhere\n  i.type in ($issue_type)\n  and date(i.created_date) BETWEEN 
curdate() - INTERVAL WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL 
WEEKDAY(curdate())+1 DAY\n  and b.id in ($board_id)",
           "refId": "A",
           "select": [
             [
@@ -179,7 +179,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select\n  case when component != '' then component else 
'Issue-without-component' end as component,\n  count(*) as 'Issue 
Number'\nfrom\n  lake.issues as i\n  join lake.board_issues bi on i.id = 
bi.issue_id\n  join boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and date(i.created_date) BETWEEN curdate() - INTERVAL 
WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL WEEKDAY(curdate())+1 DAY\n  
and b.id in ($repo_id)\ngroup by 1",
+          "rawSql": "select\n  case when component != '' then component else 
'Issue-without-component' end as component,\n  count(*) as 'Issue 
Number'\nfrom\n  lake.issues as i\n  join lake.board_issues bi on i.id = 
bi.issue_id\n  join boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and date(i.created_date) BETWEEN curdate() - INTERVAL 
WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL WEEKDAY(curdate())+1 DAY\n  
and b.id in ($board_id)\ngroup by 1",
           "refId": "A",
           "select": [
             [
@@ -331,7 +331,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select\n  i.issue_key as 'Issue Number',\n  i.title as 
'Title',\n  i.url as 'Url'\nfrom\n  lake.issues as i\n\tjoin lake.board_issues 
bi on i.id = bi.issue_id\n\tjoin lake.boards b on bi.board_id = b.id\nwhere\n  
i.type in ($issue_type)\n  and date(i.created_date) BETWEEN curdate() - 
INTERVAL WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL WEEKDAY(curdate())+1 
DAY\n  and b.id in ($repo_id)",
+          "rawSql": "select\n  i.issue_key as 'Issue Number',\n  i.title as 
'Title',\n  i.url as 'Url'\nfrom\n  lake.issues as i\n\tjoin lake.board_issues 
bi on i.id = bi.issue_id\n\tjoin lake.boards b on bi.board_id = b.id\nwhere\n  
i.type in ($issue_type)\n  and date(i.created_date) BETWEEN curdate() - 
INTERVAL WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL WEEKDAY(curdate())+1 
DAY\n  and b.id in ($board_id)",
           "refId": "A",
           "select": [
             [
@@ -412,7 +412,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select\n  count(*)\nfrom\n  lake.issues as i\n  join 
board_issues bi on i.id = bi.issue_id\n\tjoin boards b on bi.board_id = 
b.id\nwhere\n  i.type in ($issue_type)\n  and status = 'DONE'\n  and 
date(i.resolution_date) BETWEEN curdate() - INTERVAL WEEKDAY(curdate())+7 DAY 
AND curdate() - INTERVAL WEEKDAY(curdate())+1 DAY\n  and b.id in ($repo_id)",
+          "rawSql": "select\n  count(*)\nfrom\n  lake.issues as i\n  join 
board_issues bi on i.id = bi.issue_id\n\tjoin boards b on bi.board_id = 
b.id\nwhere\n  i.type in ($issue_type)\n  and status = 'DONE'\n  and 
date(i.resolution_date) BETWEEN curdate() - INTERVAL WEEKDAY(curdate())+7 DAY 
AND curdate() - INTERVAL WEEKDAY(curdate())+1 DAY\n  and b.id in ($board_id)",
           "refId": "A",
           "select": [
             [
@@ -498,7 +498,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select\n  avg(lead_time_minutes / 1440)\nfrom\n  
lake.issues as i\n\tjoin board_issues bi on i.id = bi.issue_id\n\tjoin boards b 
on bi.board_id = b.id\nwhere\n  i.type in ($issue_type)\n  and status = 
'DONE'\n  and date(i.resolution_date) BETWEEN curdate() - INTERVAL 
WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL WEEKDAY(curdate())+1 DAY\n  
and b.id in ($repo_id)",
+          "rawSql": "select\n  avg(lead_time_minutes / 1440)\nfrom\n  
lake.issues as i\n\tjoin board_issues bi on i.id = bi.issue_id\n\tjoin boards b 
on bi.board_id = b.id\nwhere\n  i.type in ($issue_type)\n  and status = 
'DONE'\n  and date(i.resolution_date) BETWEEN curdate() - INTERVAL 
WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL WEEKDAY(curdate())+1 DAY\n  
and b.id in ($board_id)",
           "refId": "A",
           "select": [
             [
@@ -546,7 +546,7 @@
               },
               {
                 "color": "red",
-                "value": 80
+                "value": 21
               }
             ]
           }
@@ -555,66 +555,48 @@
           {
             "matcher": {
               "id": "byName",
-              "options": "url"
-            },
-            "properties": [
-              {
-                "id": "links",
-                "value": [
-                  {
-                    "targetBlank": true,
-                    "title": "URL",
-                    "url": "${__value.raw}"
-                  }
-                ]
-              }
-            ]
-          },
-          {
-            "matcher": {
-              "id": "byName",
-              "options": "number"
+              "options": "Issue Number"
             },
             "properties": [
               {
                 "id": "custom.width",
-                "value": 346
+                "value": 125
               }
             ]
           },
           {
             "matcher": {
               "id": "byName",
-              "options": "title"
+              "options": "Title"
             },
             "properties": [
               {
                 "id": "custom.width",
-                "value": 754
+                "value": 541
               }
             ]
           },
           {
             "matcher": {
               "id": "byName",
-              "options": "Issue Number"
+              "options": "Url"
             },
             "properties": [
               {
                 "id": "custom.width",
-                "value": 125
+                "value": 414
               }
             ]
           },
           {
             "matcher": {
               "id": "byName",
-              "options": "Title"
+              "options": "Lead Time in Days"
             },
             "properties": [
               {
-                "id": "custom.width",
-                "value": 639
+                "id": "custom.displayMode",
+                "value": "color-text"
               }
             ]
           }
@@ -639,7 +621,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select\n  i.issue_key as 'Issue Number',\n  i.title as 
'Title',\n  i.url as 'Url'\nfrom\n  lake.issues as i\n\tjoin board_issues bi on 
i.id = bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and status = 'DONE'\n  and date(i.resolution_date) BETWEEN 
curdate() - INTERVAL WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL 
WEEKDAY(curdate())+1 DAY\n  and b.id in ($repo_id)",
+          "rawSql": "select\n  i.issue_key as 'Issue Number',\n  i.title as 
'Title',\n  lead_time_minutes/1440 as 'Lead Time in Days',\n  i.url as 
'Url'\nfrom\n  lake.issues as i\n\tjoin board_issues bi on i.id = 
bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and status = 'DONE'\n  and date(i.resolution_date) BETWEEN 
curdate() - INTERVAL WEEKDAY(curdate())+7 DAY AND curdate() - INTERVAL 
WEEKDAY(curdate())+1 DAY\n  and b.id in ($board_id)",
           "refId": "A",
           "select": [
             [
@@ -736,7 +718,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select\n  concat('#',i.issue_key, ' ', i.title) as 
issue_key,\n  lead_time_minutes/1440 as lead_time\nfrom\n  lake.issues as 
i\n\tjoin board_issues bi on i.id = bi.issue_id\n\tjoin boards b on bi.board_id 
= b.id\nwhere\n  i.type in ($issue_type)\n  and status = 'DONE'\n  and 
date(i.resolution_date) BETWEEN curdate() - INTERVAL WEEKDAY(curdate())+7 DAY 
AND curdate() - INTERVAL WEEKDAY(curdate())+1 DAY\n  and b.id in 
($repo_id)\norder by lead_time desc",
+          "rawSql": "select\n  concat('#',i.issue_key, ' ', i.title) as 
issue_key,\n  lead_time_minutes/1440 as lead_time\nfrom\n  lake.issues as 
i\n\tjoin board_issues bi on i.id = bi.issue_id\n\tjoin boards b on bi.board_id 
= b.id\nwhere\n  i.type in ($issue_type)\n  and status = 'DONE'\n  and 
date(i.resolution_date) BETWEEN curdate() - INTERVAL WEEKDAY(curdate())+7 DAY 
AND curdate() - INTERVAL WEEKDAY(curdate())+1 DAY\n  and b.id in 
($board_id)\norder by lead_time desc",
           "refId": "A",
           "select": [
             [
@@ -817,7 +799,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select\n  count(*)\nfrom \n  lake.issues i\n\tjoin 
board_issues bi on i.id = bi.issue_id\n\tjoin boards b on bi.board_id = 
b.id\nwhere\n  i.type in ($issue_type)\n  and i.status != 'DONE'\n  and b.id in 
($repo_id)",
+          "rawSql": "select\n  count(*)\nfrom \n  lake.issues i\n\tjoin 
board_issues bi on i.id = bi.issue_id\n\tjoin boards b on bi.board_id = 
b.id\nwhere\n  i.type in ($issue_type)\n  and i.status != 'DONE'\n  and b.id in 
($board_id)",
           "refId": "A",
           "select": [
             [
@@ -898,7 +880,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select \n  avg((TIMESTAMPDIFF(MINUTE, 
i.created_date,NOW()))/1440)\nfrom \n  lake.issues i\n\tjoin board_issues bi on 
i.id = bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and i.status != 'DONE'\n  and b.id in ($repo_id)",
+          "rawSql": "select \n  avg((TIMESTAMPDIFF(MINUTE, 
i.created_date,NOW()))/1440)\nfrom \n  lake.issues i\n\tjoin board_issues bi on 
i.id = bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and i.status != 'DONE'\n  and b.id in ($board_id)",
           "refId": "A",
           "select": [
             [
@@ -976,30 +958,6 @@
               }
             ]
           },
-          {
-            "matcher": {
-              "id": "byName",
-              "options": "Creation Date"
-            },
-            "properties": [
-              {
-                "id": "custom.width",
-                "value": 187
-              }
-            ]
-          },
-          {
-            "matcher": {
-              "id": "byName",
-              "options": "url"
-            },
-            "properties": [
-              {
-                "id": "custom.width",
-                "value": 492
-              }
-            ]
-          },
           {
             "matcher": {
               "id": "byName",
@@ -1027,30 +985,24 @@
           {
             "matcher": {
               "id": "byName",
-              "options": "url"
+              "options": "Queue Time in Days"
             },
             "properties": [
               {
-                "id": "links",
-                "value": [
-                  {
-                    "targetBlank": true,
-                    "title": "URL",
-                    "url": "${__value.raw}"
-                  }
-                ]
+                "id": "custom.displayMode",
+                "value": "color-text"
               }
             ]
           },
           {
             "matcher": {
               "id": "byName",
-              "options": "Queue Time in Days"
+              "options": "Url"
             },
             "properties": [
               {
-                "id": "custom.displayMode",
-                "value": "color-text"
+                "id": "custom.width",
+                "value": null
               }
             ]
           }
@@ -1075,7 +1027,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select \n  i.issue_key as 'Issue Number',\n  i.title as 
'Title',\n  (TIMESTAMPDIFF(MINUTE, i.created_date,NOW()))/1440 as 'Queue Time 
in Days',\n  i.url as 'Url'\nfrom \n  lake.issues i\n\tjoin board_issues bi on 
i.id = bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and i.status != 'DONE'\n  and b.id in ($repo_id)\norder by 
'Queue Time' desc",
+          "rawSql": "select \n  i.issue_key as 'Issue Number',\n  i.title as 
'Title',\n  (TIMESTAMPDIFF(MINUTE, i.created_date,NOW()))/1440 as 'Queue Time 
in Days',\n  i.url as 'Url'\nfrom \n  lake.issues i\n\tjoin board_issues bi on 
i.id = bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and i.status != 'DONE'\n  and b.id in ($board_id)\norder by 
'Queue Time' desc",
           "refId": "A",
           "select": [
             [
@@ -1174,7 +1126,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select \n  concat('#', i.issue_key) as issue_key,\n  
(TIMESTAMPDIFF(MINUTE, i.created_date,NOW()))/1440 as 'Queue Time in 
Days'\nfrom \n  lake.issues i\n\tjoin board_issues bi on i.id = 
bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and i.status != 'DONE'\n  and b.id in ($repo_id)\norder by 2 
desc",
+          "rawSql": "select \n  concat('#', i.issue_key) as issue_key,\n  
(TIMESTAMPDIFF(MINUTE, i.created_date,NOW()))/1440 as 'Queue Time in 
Days'\nfrom \n  lake.issues i\n\tjoin board_issues bi on i.id = 
bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and i.status != 'DONE'\n  and b.id in ($board_id)\norder by 2 
desc",
           "refId": "A",
           "select": [
             [
@@ -1228,18 +1180,6 @@
           }
         },
         "overrides": [
-          {
-            "matcher": {
-              "id": "byName",
-              "options": "Queue Time"
-            },
-            "properties": [
-              {
-                "id": "custom.width",
-                "value": 150
-              }
-            ]
-          },
           {
             "matcher": {
               "id": "byName",
@@ -1252,30 +1192,6 @@
               }
             ]
           },
-          {
-            "matcher": {
-              "id": "byName",
-              "options": "Creation Date"
-            },
-            "properties": [
-              {
-                "id": "custom.width",
-                "value": 187
-              }
-            ]
-          },
-          {
-            "matcher": {
-              "id": "byName",
-              "options": "url"
-            },
-            "properties": [
-              {
-                "id": "custom.width",
-                "value": 492
-              }
-            ]
-          },
           {
             "matcher": {
               "id": "byName",
@@ -1300,24 +1216,6 @@
               }
             ]
           },
-          {
-            "matcher": {
-              "id": "byName",
-              "options": "url"
-            },
-            "properties": [
-              {
-                "id": "links",
-                "value": [
-                  {
-                    "targetBlank": true,
-                    "title": "URL",
-                    "url": "${__value.raw}"
-                  }
-                ]
-              }
-            ]
-          },
           {
             "matcher": {
               "id": "byName",
@@ -1351,7 +1249,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "select \n  i.issue_key as 'Issue Number',\n  i.title as 
'Title',\n  (TIMESTAMPDIFF(MINUTE, i.created_date,NOW()))/1440 as 'Queue Time 
in Days',\n  i.url as 'Url'\nfrom \n  lake.issues i\n\tjoin board_issues bi on 
i.id = bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and i.status != 'DONE'\n  and i.assignee_name = ''\n  and b.id 
in ($repo_id)\norder by 'Queue Time' desc",
+          "rawSql": "select \n  i.issue_key as 'Issue Number',\n  i.title as 
'Title',\n  (TIMESTAMPDIFF(MINUTE, i.created_date,NOW()))/1440 as 'Queue Time 
in Days',\n  i.url as 'Url'\nfrom \n  lake.issues i\n\tjoin board_issues bi on 
i.id = bi.issue_id\n\tjoin boards b on bi.board_id = b.id\nwhere\n  i.type in 
($issue_type)\n  and i.status != 'DONE'\n  and i.assignee_name = ''\n  and b.id 
in ($board_id)\norder by 'Queue Time' desc",
           "refId": "A",
           "select": [
             [
@@ -1446,7 +1344,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "with bugs as (  \n  select \n    
DATE_ADD(date(i.created_date), INTERVAL -WEEKDAY(date(i.created_date)) DAY) as 
time,\n    count(*) as bug_count\n  from\n    lake.issues as i\n\t  join 
lake.board_issues bi on i.id = bi.issue_id\n\t  join lake.boards b on 
bi.board_id = b.id\n  where \n    i.type in ($issue_type)\n    and 
$__timeFilter(i.created_date)\n    and b.id in ($repo_id)\n  group by time\n  
order by time desc\n),\n\ncalendar_date as(\n\tSELECT CAST((SYSDATE()-I [...]
+          "rawSql": "with bugs as (  \n  select \n    
DATE_ADD(date(i.created_date), INTERVAL -WEEKDAY(date(i.created_date)) DAY) as 
time,\n    count(*) as bug_count\n  from\n    lake.issues as i\n\t  join 
lake.board_issues bi on i.id = bi.issue_id\n\t  join lake.boards b on 
bi.board_id = b.id\n  where \n    i.type in ($issue_type)\n    and 
$__timeFilter(i.created_date)\n    and b.id in ($board_id)\n  group by time\n  
order by time desc\n),\n\ncalendar_date as(\n\tSELECT CAST((SYSDATE()- [...]
           "refId": "A",
           "select": [
             [
@@ -1541,7 +1439,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "with bugs as (\n  select \n    
DATE_ADD(date(i.resolution_date), INTERVAL -WEEKDAY(date(i.resolution_date)) 
DAY) as time,\n    count(*) as bug_count\n  from\n    lake.issues as i\n\t  
join lake.board_issues bi on i.id = bi.issue_id\n\t  join lake.boards b on 
bi.board_id = b.id\n  where \n    i.type in ($issue_type)\n    and status = 
'DONE'\n    and $__timeFilter(i.resolution_date)\n    and b.id in ($repo_id)\n  
group by time\n  order by time desc\n),\n\ncalendar_date [...]
+          "rawSql": "with bugs as (\n  select \n    
DATE_ADD(date(i.resolution_date), INTERVAL -WEEKDAY(date(i.resolution_date)) 
DAY) as time,\n    count(*) as bug_count\n  from\n    lake.issues as i\n\t  
join lake.board_issues bi on i.id = bi.issue_id\n\t  join lake.boards b on 
bi.board_id = b.id\n  where \n    i.type in ($issue_type)\n    and status = 
'DONE'\n    and $__timeFilter(i.resolution_date)\n    and b.id in ($board_id)\n 
 group by time\n  order by time desc\n),\n\ncalendar_dat [...]
           "refId": "A",
           "select": [
             [
@@ -1638,7 +1536,7 @@
           "metricColumn": "none",
           "queryType": "randomWalk",
           "rawQuery": true,
-          "rawSql": "with calendar_date as(\n\tSELECT CAST((SYSDATE()-INTERVAL 
(H+T+U) DAY) AS date) d\n\tFROM ( SELECT 0 H\n\t\t\tUNION ALL SELECT 100 UNION 
ALL SELECT 200 UNION ALL SELECT 300\n\t\t) H CROSS JOIN ( SELECT 0 
T\n\t\t\tUNION ALL SELECT  10 UNION ALL SELECT  20 UNION ALL SELECT  
30\n\t\t\tUNION ALL SELECT  40 UNION ALL SELECT  50 UNION ALL SELECT  
60\n\t\t\tUNION ALL SELECT  70 UNION ALL SELECT  80 UNION ALL SELECT  90\n\t\t) 
T CROSS JOIN ( SELECT 0 U\n\t\t\tUNION ALL SELEC [...]
+          "rawSql": "with calendar_date as(\n\tSELECT CAST((SYSDATE()-INTERVAL 
(H+T+U) DAY) AS date) d\n\tFROM ( SELECT 0 H\n\t\t\tUNION ALL SELECT 100 UNION 
ALL SELECT 200 UNION ALL SELECT 300\n\t\t) H CROSS JOIN ( SELECT 0 
T\n\t\t\tUNION ALL SELECT  10 UNION ALL SELECT  20 UNION ALL SELECT  
30\n\t\t\tUNION ALL SELECT  40 UNION ALL SELECT  50 UNION ALL SELECT  
60\n\t\t\tUNION ALL SELECT  70 UNION ALL SELECT  80 UNION ALL SELECT  90\n\t\t) 
T CROSS JOIN ( SELECT 0 U\n\t\t\tUNION ALL SELEC [...]
           "refId": "A",
           "select": [
             [
@@ -1701,16 +1599,16 @@
           "value": "$__all"
         },
         "datasource": "mysql",
-        "definition": "select concat(name, '-', id) as text from repos",
+        "definition": "select concat(name, '-', id) as text from boards",
         "description": null,
         "error": null,
         "hide": 0,
         "includeAll": true,
-        "label": "Repo",
+        "label": "Board",
         "multi": false,
-        "name": "repo_id",
+        "name": "board_id",
         "options": [],
-        "query": "select concat(name, '-', id) as text from repos",
+        "query": "select concat(name, '-', id) as text from boards",
         "refresh": 1,
         "regex": "/^(?<text>.*)-(?<value>.*)$/",
         "skipUrlSync": false,
@@ -1751,5 +1649,5 @@
   "timezone": "",
   "title": "Weekly Bug Retro",
   "uid": "-5EKA5w7k",
-  "version": 6
+  "version": 15
 }
\ No newline at end of file


Reply via email to