BarChart: add gdev panel for random threshold from query (#58580)

This commit is contained in:
Leon Sorokin 2022-11-11 09:58:08 -06:00 committed by GitHub
parent 8edeb1aa22
commit 860e25df3c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -24,7 +24,6 @@
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 0,
"id": 114,
"links": [],
"liveNow": false,
"panels": [
@ -684,6 +683,127 @@
"title": "override value mappings",
"type": "barchart"
},
{
"datasource": {
"type": "testdata",
"uid": "PD8C576611E62080A"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "thresholds"
},
"custom": {
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"axisSoftMin": 0,
"fillOpacity": 50,
"gradientMode": "scheme",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"lineWidth": 1,
"scaleDistribution": {
"type": "linear"
},
"thresholdsStyle": {
"mode": "dashed"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green"
},
{
"color": "red",
"value": 80
}
]
}
},
"overrides": []
},
"gridPos": {
"h": 9,
"w": 5,
"x": 10,
"y": 9
},
"id": 14,
"maxDataPoints": 1,
"options": {
"barRadius": 0,
"barWidth": 0.97,
"groupWidth": 0.7,
"legend": {
"calcs": [],
"displayMode": "list",
"placement": "bottom",
"showLegend": true
},
"orientation": "auto",
"showValue": "auto",
"stacking": "none",
"tooltip": {
"mode": "single",
"sort": "none"
},
"xTickLabelRotation": 0,
"xTickLabelSpacing": 0
},
"targets": [
{
"csvContent": "label,value\nx,3\na,10\nb,20\nc,30",
"datasource": {
"type": "testdata",
"uid": "PD8C576611E62080A"
},
"refId": "A",
"scenarioId": "csv_content"
},
{
"datasource": {
"type": "testdata",
"uid": "PD8C576611E62080A"
},
"hide": false,
"max": 30,
"min": 0.01,
"noise": 30,
"refId": "B",
"scenarioId": "random_walk",
"spread": 0,
"startValue": 1
}
],
"title": "threshold from random walk",
"transformations": [
{
"id": "configFromData",
"options": {
"applyTo": {
"id": "byType",
"options": "number"
},
"configRefId": "B",
"mappings": [
{
"fieldName": "B-series",
"handlerKey": "threshold1"
}
]
}
}
],
"type": "barchart"
},
{
"datasource": {
"type": "testdata",
@ -1138,6 +1258,6 @@
"timezone": "",
"title": "BarChart - Thresholds & Mappings",
"uid": "2I2uMSB7z",
"version": 25,
"version": 32,
"weekStart": ""
}