mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2025-12-22 22:20:02 +00:00
* feat: add description for each grafana panel * Apply suggestions from code review Co-authored-by: Yingwen <realevenyag@gmail.com> * fix: unit of write stall * feat: add jq script to summary the grafana dashboard * fix: update description * ci: add ci step to valid grafana and send summary as comment * ci: update check * ci: update ci --------- Co-authored-by: Yingwen <realevenyag@gmail.com>
20 lines
575 B
Bash
Executable File
20 lines
575 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
BASEDIR=$(dirname "$0")
|
|
|
|
# Use jq to check for panels with empty or missing descriptions
|
|
invalid_panels=$(cat $BASEDIR/greptimedb-cluster.json | jq -r '
|
|
.panels[]
|
|
| select((.type == "stats" or .type == "timeseries") and (.description == "" or .description == null))
|
|
')
|
|
|
|
# Check if any invalid panels were found
|
|
if [[ -n "$invalid_panels" ]]; then
|
|
echo "Error: The following panels have empty or missing descriptions:"
|
|
echo "$invalid_panels"
|
|
exit 1
|
|
else
|
|
echo "All panels with type 'stats' or 'timeseries' have valid descriptions."
|
|
exit 0
|
|
fi
|