mirror of
https://github.com/AsgardEternal/grafana-dashboards.git
synced 2025-01-02 12:09:17 -06:00
205 lines
4.7 KiB
JSON
205 lines
4.7 KiB
JSON
{
|
|
"__inputs": [
|
|
{
|
|
"name": "DS_MYSQL",
|
|
"label": "MySQL",
|
|
"description": "",
|
|
"type": "datasource",
|
|
"pluginId": "mysql",
|
|
"pluginName": "MySQL"
|
|
}
|
|
],
|
|
"__elements": {},
|
|
"__requires": [
|
|
{
|
|
"type": "grafana",
|
|
"id": "grafana",
|
|
"name": "Grafana",
|
|
"version": "9.4.7"
|
|
},
|
|
{
|
|
"type": "datasource",
|
|
"id": "mysql",
|
|
"name": "MySQL",
|
|
"version": "1.0.0"
|
|
},
|
|
{
|
|
"type": "panel",
|
|
"id": "timeseries",
|
|
"name": "Time series",
|
|
"version": ""
|
|
}
|
|
],
|
|
"annotations": {
|
|
"list": [
|
|
{
|
|
"builtIn": 1,
|
|
"datasource": {
|
|
"type": "grafana",
|
|
"uid": "-- Grafana --"
|
|
},
|
|
"enable": true,
|
|
"hide": true,
|
|
"iconColor": "rgba(0, 211, 255, 1)",
|
|
"name": "Annotations & Alerts",
|
|
"target": {
|
|
"limit": 100,
|
|
"matchAny": false,
|
|
"tags": [],
|
|
"type": "dashboard"
|
|
},
|
|
"type": "dashboard"
|
|
}
|
|
]
|
|
},
|
|
"editable": true,
|
|
"fiscalYearStartMonth": 0,
|
|
"graphTooltip": 0,
|
|
"id": null,
|
|
"links": [],
|
|
"liveNow": false,
|
|
"panels": [
|
|
{
|
|
"datasource": {
|
|
"type": "mysql",
|
|
"uid": "${DS_MYSQL}"
|
|
},
|
|
"fieldConfig": {
|
|
"defaults": {
|
|
"color": {
|
|
"mode": "thresholds"
|
|
},
|
|
"custom": {
|
|
"axisCenteredZero": false,
|
|
"axisColorMode": "text",
|
|
"axisGridShow": true,
|
|
"axisLabel": "",
|
|
"axisPlacement": "auto",
|
|
"barAlignment": 1,
|
|
"drawStyle": "bars",
|
|
"fillOpacity": 100,
|
|
"gradientMode": "scheme",
|
|
"hideFrom": {
|
|
"legend": false,
|
|
"tooltip": false,
|
|
"viz": false
|
|
},
|
|
"lineInterpolation": "linear",
|
|
"lineWidth": 0,
|
|
"pointSize": 10,
|
|
"scaleDistribution": {
|
|
"type": "linear"
|
|
},
|
|
"showPoints": "auto",
|
|
"spanNulls": false,
|
|
"stacking": {
|
|
"group": "A",
|
|
"mode": "none"
|
|
},
|
|
"thresholdsStyle": {
|
|
"mode": "off"
|
|
}
|
|
},
|
|
"mappings": [],
|
|
"min": 0,
|
|
"thresholds": {
|
|
"mode": "absolute",
|
|
"steps": [
|
|
{
|
|
"color": "dark-green",
|
|
"value": null
|
|
},
|
|
{
|
|
"color": "green",
|
|
"value": 1
|
|
},
|
|
{
|
|
"color": "orange",
|
|
"value": 2
|
|
},
|
|
{
|
|
"color": "red",
|
|
"value": 3
|
|
},
|
|
{
|
|
"color": "dark-red",
|
|
"value": 4
|
|
}
|
|
]
|
|
},
|
|
"unit": "h"
|
|
},
|
|
"overrides": []
|
|
},
|
|
"gridPos": {
|
|
"h": 9,
|
|
"w": 24,
|
|
"x": 0,
|
|
"y": 0
|
|
},
|
|
"id": 2,
|
|
"options": {
|
|
"legend": {
|
|
"calcs": [],
|
|
"displayMode": "list",
|
|
"placement": "bottom",
|
|
"showLegend": false
|
|
},
|
|
"tooltip": {
|
|
"mode": "single",
|
|
"sort": "none"
|
|
}
|
|
},
|
|
"targets": [
|
|
{
|
|
"datasource": {
|
|
"type": "mysql",
|
|
"uid": "${DS_MYSQL}"
|
|
},
|
|
"editorMode": "code",
|
|
"format": "table",
|
|
"rawQuery": true,
|
|
"rawSql": "select startTime, seedtime\nfrom (\nselect startTime, time_to_sec(timediff(ifnull(endTime,now()), startTime))/3600 as seedtime, DBLog_Matches.server, max(players) as mplayers\nfrom DBLog_Matches join DBLog_PlayerCounts DLPC on DBLog_Matches.id = DLPC.`match`\nwhere $__timeFilter(startTime) and \n layerClassname regexp '_Seed_' and\n DBLog_Matches.server = 1\ngroup by DBLog_Matches.id\norder by mplayers desc\n) as base\nwhere mplayers > 50\norder by startTime",
|
|
"refId": "A",
|
|
"sql": {
|
|
"columns": [
|
|
{
|
|
"parameters": [],
|
|
"type": "function"
|
|
}
|
|
],
|
|
"groupBy": [
|
|
{
|
|
"property": {
|
|
"type": "string"
|
|
},
|
|
"type": "groupBy"
|
|
}
|
|
],
|
|
"limit": 50
|
|
}
|
|
}
|
|
],
|
|
"title": "Panel Title",
|
|
"type": "timeseries"
|
|
}
|
|
],
|
|
"refresh": "",
|
|
"revision": 1,
|
|
"schemaVersion": 38,
|
|
"style": "dark",
|
|
"tags": [],
|
|
"templating": {
|
|
"list": []
|
|
},
|
|
"time": {
|
|
"from": "now-30d",
|
|
"to": "now"
|
|
},
|
|
"timepicker": {},
|
|
"timezone": "",
|
|
"title": "seeding stats",
|
|
"uid": "UXpUNoL4z",
|
|
"version": 4,
|
|
"weekStart": ""
|
|
} |