Skip to content

Commit 31a62fc

Browse files
committed
feat: optimize pg kernel color schema
1 parent 6c66ba6 commit 31a62fc

6 files changed

Lines changed: 27 additions & 21 deletions

File tree

conf/demo/kernel.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,20 +16,20 @@ all:
1616
etcd: { hosts: { 10.10.10.10: { etcd_seq: 1 } }, vars: { etcd_cluster: etcd } }
1717

1818
# 1. Vanilla PostgreSQL + Citus in one kernel template
19-
pg-meta:
19+
pg-citus:
2020
hosts:
2121
10.10.10.10: { pg_seq: 1, pg_role: primary }
2222
vars:
2323
pg_cluster: pg-citus
2424
pg_version: 18
25-
pg_packages: [ pgsql-main, pgsql-common, citus, timescaledb ]
25+
pg_packages: [ pgsql-main, pgsql-common, citus ]
2626
pg_users:
2727
- { name: dbuser_meta ,password: DBUser.Meta ,pgbouncer: true ,roles: [dbrole_admin] ,comment: pigsty admin user }
2828
- { name: dbuser_view ,password: DBUser.Viewer ,pgbouncer: true ,roles: [dbrole_readonly] ,comment: read-only viewer }
2929
pg_databases:
3030
- { name: meta ,baseline: cmdb.sql ,comment: pigsty meta database ,schemas: [pigsty] ,extensions: [citus, postgis, timescaledb, vector] }
3131
pg_extensions: [ citus, postgis, timescaledb, pgvector ]
32-
pg_libs: 'citus, timescaledb, pg_stat_statements, auto_explain'
32+
pg_libs: 'citus, pg_stat_statements, auto_explain'
3333

3434
# 2. IvorySQL kernel
3535
pg-ivory:

files/grafana/pgsql/pgrds-cluster.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -187,9 +187,10 @@
187187
{
188188
"id":"mappings",
189189
"value":[
190-
{ "options":{"pattern":".*Percona.*","result":{"color":"dark-orange","index":0,"text":"Percona"}} ,"type":"regex" },{ "options":{"pattern":".*[Bb]abelfish.*","result":{"color":"#d82024e3","index":1,"text":"Babelfish"}},"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#f25009","index":2,"text":"PolarDB"}} ,"type":"regex" },
191-
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#ee9832","index":3,"text":"IvorySQL"}} ,"type":"regex" },{ "options":{"pattern":".*[Aa]gens[Gg]raph.*","result":{"color":"#FDC425","index":4,"text":"AgensGraph"}},"type":"regex" },{ "options":{"pattern":".*(pgedge|pgEdge).*","result":{"color":"#218CB4","index":5,"text":"pgEdge"}},"type":"regex" },
192-
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3e668f","index":6,"text":"PostgreSQL"}} ,"type":"regex" },{ "options":{"pattern":"openHalo.*","result":{"color":"#ba5bb8","index":7,"text":"OpenHalo"}} ,"type":"regex" },{ "options":{"pattern":"OrioleDB.*","result":{"color":"#1f4085","index":8,"text":"OrioleDB"}} ,"type":"regex" }
190+
{ "options":{"pattern":".*Percona.*","result":{"color":"#417EA7","index":0,"text":"Percona"}} ,"type":"regex" },{ "options":{"pattern":".*Babelfish.*","result":{"color":"#cc4637d9","index":1,"text":"Babelfish"}} ,"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#E06623","index":2,"text":"PolarDB"}} ,"type":"regex" },
191+
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#E4A449","index":3,"text":"IvorySQL"}} ,"type":"regex" },{ "options":{"pattern":".*openHalo.*","result":{"color":"#7771A4","index":4,"text":"OpenHalo"}} ,"type":"regex" },{ "options":{"pattern":".*OrioleDB.*","result":{"color":"#1D387A","index":5,"text":"OrioleDB"}} ,"type":"regex" },
192+
{ "options":{"pattern":".*AgensGraph.*","result":{"color":"#B783AF","index":6,"text":"AgensGraph"}},"type":"regex" },{ "options":{"pattern":".*(pgEdge|pgedge).*","result":{"color":"#5B9CD5","index":7,"text":"pgEdge"}} ,"type":"regex" },{ "options":{"pattern":".*Cloudberry.*","result":{"color":"#6C6C6C","index":8,"text":"Cloudberry"}},"type":"regex" },
193+
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3E668F","index":9,"text":"PostgreSQL"}} ,"type":"regex" }
193194
]
194195
}
195196
]

files/grafana/pgsql/pgrds-instance.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -187,9 +187,10 @@
187187
{
188188
"id":"mappings",
189189
"value":[
190-
{ "options":{"pattern":".*Percona.*","result":{"color":"dark-orange","index":0,"text":"Percona"}} ,"type":"regex" },{ "options":{"pattern":".*[Bb]abelfish.*","result":{"color":"#d82024e3","index":1,"text":"Babelfish"}},"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#f25009","index":2,"text":"PolarDB"}} ,"type":"regex" },
191-
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#ee9832","index":3,"text":"IvorySQL"}} ,"type":"regex" },{ "options":{"pattern":".*[Aa]gens[Gg]raph.*","result":{"color":"#FDC425","index":4,"text":"AgensGraph"}},"type":"regex" },{ "options":{"pattern":".*(pgedge|pgEdge).*","result":{"color":"#218CB4","index":5,"text":"pgEdge"}},"type":"regex" },
192-
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3e668f","index":6,"text":"PostgreSQL"}} ,"type":"regex" },{ "options":{"pattern":"openHalo.*","result":{"color":"#ba5bb8","index":7,"text":"OpenHalo"}} ,"type":"regex" },{ "options":{"pattern":"OrioleDB.*","result":{"color":"#1f4085","index":8,"text":"OrioleDB"}} ,"type":"regex" }
190+
{ "options":{"pattern":".*Percona.*","result":{"color":"#417EA7","index":0,"text":"Percona"}} ,"type":"regex" },{ "options":{"pattern":".*Babelfish.*","result":{"color":"#cc4637d9","index":1,"text":"Babelfish"}} ,"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#E06623","index":2,"text":"PolarDB"}} ,"type":"regex" },
191+
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#E4A449","index":3,"text":"IvorySQL"}} ,"type":"regex" },{ "options":{"pattern":".*openHalo.*","result":{"color":"#7771A4","index":4,"text":"OpenHalo"}} ,"type":"regex" },{ "options":{"pattern":".*OrioleDB.*","result":{"color":"#1D387A","index":5,"text":"OrioleDB"}} ,"type":"regex" },
192+
{ "options":{"pattern":".*AgensGraph.*","result":{"color":"#B783AF","index":6,"text":"AgensGraph"}},"type":"regex" },{ "options":{"pattern":".*(pgEdge|pgedge).*","result":{"color":"#5B9CD5","index":7,"text":"pgEdge"}} ,"type":"regex" },{ "options":{"pattern":".*Cloudberry.*","result":{"color":"#6C6C6C","index":8,"text":"Cloudberry"}},"type":"regex" },
193+
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3E668F","index":9,"text":"PostgreSQL"}} ,"type":"regex" }
193194
]
194195
}
195196
]

files/grafana/pgsql/pgsql-cluster.json

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,10 @@
2626
{
2727
"id":"mappings",
2828
"value":[
29-
{ "options":{"pattern":".*Percona.*","result":{"color":"dark-orange","index":0,"text":"Percona"}} ,"type":"regex" },{ "options":{"pattern":".*[Bb]abelfish.*","result":{"color":"#d82024e3","index":1,"text":"Babelfish"}},"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#f25009","index":2,"text":"PolarDB"}} ,"type":"regex" },
30-
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#ee9832","index":3,"text":"IvorySQL"}} ,"type":"regex" },{ "options":{"pattern":".*[Aa]gens[Gg]raph.*","result":{"color":"#FDC425","index":4,"text":"AgensGraph"}},"type":"regex" },{ "options":{"pattern":".*(pgedge|pgEdge).*","result":{"color":"#218CB4","index":5,"text":"pgEdge"}},"type":"regex" },
31-
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3e668f","index":6,"text":"PostgreSQL"}} ,"type":"regex" },{ "options":{"pattern":"openHalo.*","result":{"color":"#ba5bb8","index":7,"text":"OpenHalo"}} ,"type":"regex" },{ "options":{"pattern":"OrioleDB.*","result":{"color":"#1f4085","index":8,"text":"OrioleDB"}} ,"type":"regex" }
29+
{ "options":{"pattern":".*Percona.*","result":{"color":"#417EA7","index":0,"text":"Percona"}} ,"type":"regex" },{ "options":{"pattern":".*Babelfish.*","result":{"color":"#cc4637d9","index":1,"text":"Babelfish"}} ,"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#E06623","index":2,"text":"PolarDB"}} ,"type":"regex" },
30+
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#E4A449","index":3,"text":"IvorySQL"}} ,"type":"regex" },{ "options":{"pattern":".*openHalo.*","result":{"color":"#7771A4","index":4,"text":"OpenHalo"}} ,"type":"regex" },{ "options":{"pattern":".*OrioleDB.*","result":{"color":"#1D387A","index":5,"text":"OrioleDB"}} ,"type":"regex" },
31+
{ "options":{"pattern":".*AgensGraph.*","result":{"color":"#B783AF","index":6,"text":"AgensGraph"}},"type":"regex" },{ "options":{"pattern":".*(pgEdge|pgedge).*","result":{"color":"#5B9CD5","index":7,"text":"pgEdge"}} ,"type":"regex" },{ "options":{"pattern":".*Cloudberry.*","result":{"color":"#6C6C6C","index":8,"text":"Cloudberry"}},"type":"regex" },
32+
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3E668F","index":9,"text":"PostgreSQL"}} ,"type":"regex" }
3233
]
3334
}
3435
]
@@ -1001,9 +1002,10 @@
10011002
"datasource":{"type":"prometheus","uid":"ds-prometheus"},
10021003
"description":"",
10031004
"fieldConfig":{"defaults":{"color":{"mode":"thresholds"},"mappings":[
1004-
{ "options":{"pattern":".*Percona.*","result":{"color":"dark-orange","index":0}},"type":"regex" },{ "options":{"pattern":".*[Bb]abelfish.*","result":{"color":"#d82024e3","index":1}},"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#f25009","index":2}},"type":"regex" },
1005-
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#ee9832","index":3}},"type":"regex" },{ "options":{"pattern":".*[Aa]gens[Gg]raph.*","result":{"color":"#FDC425","index":4}},"type":"regex" },{ "options":{"pattern":".*(pgedge|pgEdge).*","result":{"color":"#218CB4","index":5}},"type":"regex" },
1006-
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3e668f","index":6}},"type":"regex" },{ "options":{"pattern":"openHalo.*","result":{"color":"#ba5bb8","index":7}},"type":"regex" },{ "options":{"pattern":"OrioleDB.*","result":{"color":"#1f4085","index":8}},"type":"regex" }
1005+
{ "options":{"pattern":".*Percona.*","result":{"color":"#417EA7","index":0}},"type":"regex" },{ "options":{"pattern":".*Babelfish.*","result":{"color":"#cc4637d9","index":1}},"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#E06623","index":2}},"type":"regex" },
1006+
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#E4A449","index":3}},"type":"regex" },{ "options":{"pattern":".*openHalo.*","result":{"color":"#7771A4","index":4}},"type":"regex" },{ "options":{"pattern":".*OrioleDB.*","result":{"color":"#1D387A","index":5}},"type":"regex" },
1007+
{ "options":{"pattern":".*AgensGraph.*","result":{"color":"#B783AF","index":6}},"type":"regex" },{ "options":{"pattern":".*(pgEdge|pgedge).*","result":{"color":"#5B9CD5","index":7}},"type":"regex" },{ "options":{"pattern":".*Cloudberry.*","result":{"color":"#6C6C6C","index":8}},"type":"regex" },
1008+
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3E668F","index":9}},"type":"regex" }
10071009
],"thresholds":{"mode":"absolute","steps":[{"color":"#3e668f","value":0}]},"unit":"string"},"overrides":[]},
10081010
"gridPos":{"h":1,"w":24,"x":0,"y":37},
10091011
"id":187,

files/grafana/pgsql/pgsql-instance.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -780,9 +780,10 @@
780780
"datasource":{"type":"prometheus","uid":"ds-prometheus"},
781781
"description":"",
782782
"fieldConfig":{"defaults":{"color":{"mode":"thresholds"},"mappings":[
783-
{ "options":{"pattern":".*Percona.*","result":{"color":"dark-orange","index":0}},"type":"regex" },{ "options":{"pattern":".*[Bb]abelfish.*","result":{"color":"#d82024e3","index":1}},"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#f25009","index":2}},"type":"regex" },
784-
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#ee9832","index":3}},"type":"regex" },{ "options":{"pattern":".*[Aa]gens[Gg]raph.*","result":{"color":"#FDC425","index":4}},"type":"regex" },{ "options":{"pattern":".*(pgedge|pgEdge).*","result":{"color":"#218CB4","index":5}},"type":"regex" },
785-
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3e668f","index":6}},"type":"regex" },{ "options":{"pattern":"openHalo.*","result":{"color":"#ba5bb8","index":7}},"type":"regex" },{ "options":{"pattern":"OrioleDB.*","result":{"color":"#1f4085","index":8}},"type":"regex" }
783+
{ "options":{"pattern":".*Percona.*","result":{"color":"#417EA7","index":0}},"type":"regex" },{ "options":{"pattern":".*Babelfish.*","result":{"color":"#cc4637d9","index":1}},"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#E06623","index":2}},"type":"regex" },
784+
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#E4A449","index":3}},"type":"regex" },{ "options":{"pattern":".*openHalo.*","result":{"color":"#7771A4","index":4}},"type":"regex" },{ "options":{"pattern":".*OrioleDB.*","result":{"color":"#1D387A","index":5}},"type":"regex" },
785+
{ "options":{"pattern":".*AgensGraph.*","result":{"color":"#B783AF","index":6}},"type":"regex" },{ "options":{"pattern":".*(pgEdge|pgedge).*","result":{"color":"#5B9CD5","index":7}},"type":"regex" },{ "options":{"pattern":".*Cloudberry.*","result":{"color":"#6C6C6C","index":8}},"type":"regex" },
786+
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3E668F","index":9}},"type":"regex" }
786787
],"thresholds":{"mode":"absolute","steps":[{"color":"#3e668f","value":0}]},"unit":"string"},"overrides":[]},
787788
"gridPos":{"h":1,"w":24,"x":0,"y":24},
788789
"id":133,

files/grafana/pgsql/pgsql-overview.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -614,9 +614,10 @@
614614
{
615615
"id":"mappings",
616616
"value":[
617-
{ "options":{"pattern":"PostgreSQL.*Percona.*","result":{"color":"#E55400","index":0,"text":"Percona"}},"type":"regex" },{ "options":{"pattern":".*[Bb]abelfish.*","result":{"color":"#d82024e3","index":1,"text":"Babelfish"}} ,"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#f25009","index":2,"text":"PolarDB"}} ,"type":"regex" },
618-
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#ee9832","index":3,"text":"IvorySQL"}} ,"type":"regex" },{ "options":{"pattern":".*[Aa]gens[Gg]raph.*","result":{"color":"#FDC425","index":4,"text":"AgensGraph"}},"type":"regex" },{ "options":{"pattern":".*(pgedge|pgEdge).*","result":{"color":"#218CB4","index":5,"text":"pgEdge"}},"type":"regex" },
619-
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3e668f","index":6,"text":"PostgreSQL"}} ,"type":"regex" },{ "options":{"pattern":"openHalo.*","result":{"color":"#ba5bb8","index":7,"text":"OpenHalo"}} ,"type":"regex" },{ "options":{"pattern":"OrioleDB.*","result":{"color":"#1f4085","index":8,"text":"OrioleDB"}} ,"type":"regex" }
617+
{ "options":{"pattern":".*Percona.*","result":{"color":"#417EA7","index":0,"text":"Percona"}} ,"type":"regex" },{ "options":{"pattern":".*Babelfish.*","result":{"color":"#cc4637d9","index":1,"text":"Babelfish"}} ,"type":"regex" },{ "options":{"pattern":".*PolarDB.*","result":{"color":"#E06623","index":2,"text":"PolarDB"}} ,"type":"regex" },
618+
{ "options":{"pattern":".*IvorySQL.*","result":{"color":"#E4A449","index":3,"text":"IvorySQL"}} ,"type":"regex" },{ "options":{"pattern":".*openHalo.*","result":{"color":"#7771A4","index":4,"text":"OpenHalo"}} ,"type":"regex" },{ "options":{"pattern":".*OrioleDB.*","result":{"color":"#1D387A","index":5,"text":"OrioleDB"}} ,"type":"regex" },
619+
{ "options":{"pattern":".*AgensGraph.*","result":{"color":"#B783AF","index":6,"text":"AgensGraph"}} ,"type":"regex" },{ "options":{"pattern":".*(pgEdge|pgedge).*","result":{"color":"#5B9CD5","index":7,"text":"pgEdge"}} ,"type":"regex" },{ "options":{"pattern":".*Cloudberry.*","result":{"color":"#6C6C6C","index":8,"text":"Cloudberry"}} ,"type":"regex" },
620+
{ "options":{"pattern":"PostgreSQL.*","result":{"color":"#3E668F","index":9,"text":"PostgreSQL"}} ,"type":"regex" }
620621
]
621622
},
622623
{"id":"color"},{"id":"custom.cellOptions","value":{"type":"color-background"}}

0 commit comments

Comments
 (0)