Skip to content
This repository has been archived by the owner on Oct 27, 2020. It is now read-only.

Commit

Permalink
efficient string concat
Browse files Browse the repository at this point in the history
  • Loading branch information
GRECO, FRANK committed Sep 24, 2017
1 parent c770d35 commit 8d6eff1
Show file tree
Hide file tree
Showing 4 changed files with 569 additions and 56 deletions.
279 changes: 269 additions & 10 deletions grafana.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
"gnetId": null,
"graphTooltip": 0,
"hideControls": false,
"id": null,
"id": 1,
"links": [],
"refresh": "1m",
"rows": [
Expand Down Expand Up @@ -1207,7 +1207,7 @@
{
"columns": [],
"datasource": "kanali",
"description": "average response time per proxy",
"description": "average proxy response time per proxy",
"fontSize": "100%",
"id": 3,
"links": [],
Expand Down Expand Up @@ -1296,15 +1296,124 @@
"tags": []
}
],
"title": "Avg Response Time by API Proxy",
"title": "Average Proxy Response Time by API Proxy",
"transform": "table",
"transparent": false,
"type": "table"
},
{
"columns": [],
"datasource": "kanali",
"description": "total requests by api key",
"description": "average target response time per proxy",
"fontSize": "100%",
"id": 12,
"links": [],
"pageSize": null,
"scroll": true,
"showHeader": true,
"sort": {
"col": 2,
"desc": false
},
"span": 6,
"styles": [
{
"alias": "Proxy Name",
"colorMode": null,
"colors": [],
"dateFormat": "YYYY-MM-DD HH:mm:ss",
"decimals": 2,
"pattern": "proxy_name",
"preserveFormat": false,
"sanitize": false,
"thresholds": [],
"type": "string",
"unit": "short"
},
{
"alias": "Avg Response Time",
"colorMode": "value",
"colors": [
"rgb(80, 177, 132)",
"rgb(255, 204, 102)",
"rgb(222, 107, 115)"
],
"dateFormat": "YYYY-MM-DD HH:mm:ss",
"decimals": 0,
"pattern": "mean",
"thresholds": [
"500",
"1000"
],
"type": "number",
"unit": "ms"
},
{
"alias": "remove",
"colorMode": null,
"colors": [],
"dateFormat": "YYYY-MM-DD HH:mm:ss",
"decimals": 2,
"pattern": "Time",
"thresholds": [],
"type": "hidden",
"unit": "short"
}
],
"targets": [
{
"dsType": "influxdb",
"groupBy": [
{
"params": [
"proxy_name"
],
"type": "tag"
}
],
"measurement": "request_details",
"orderByTime": "ASC",
"policy": "default",
"refId": "A",
"resultFormat": "table",
"select": [
[
{
"params": [
"total_target_time"
],
"type": "field"
},
{
"params": [],
"type": "mean"
}
]
],
"tags": []
}
],
"title": "Average Target Response Time by API Proxy",
"transform": "table",
"transparent": false,
"type": "table"
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "By Proxy",
"titleSize": "h6"
},
{
"collapse": false,
"height": 250,
"panels": [
{
"columns": [],
"datasource": "kanali",
"description": "total requests by api proxy",
"fontSize": "100%",
"id": 4,
"links": [],
Expand Down Expand Up @@ -1367,7 +1476,7 @@
"groupBy": [
{
"params": [
"api_key_name"
"proxy_name"
],
"type": "tag"
}
Expand All @@ -1393,17 +1502,138 @@
],
"tags": [
{
"key": "api_key_name",
"key": "proxy_name",
"operator": "!=",
"value": "none"
}
]
}
],
"title": "Requests by API Key",
"title": "Total Requests by API Proxy",
"transform": "table",
"type": "table"
},
{
"columns": [],
"datasource": "kanali",
"description": "total requests by api key",
"fontSize": "100%",
"id": 13,
"links": [],
"pageSize": null,
"scroll": true,
"showHeader": true,
"sort": {
"col": 2,
"desc": true
},
"span": 6,
"styles": [
{
"alias": "API Key Name",
"dateFormat": "YYYY-MM-DD HH:mm:ss",
"decimals": 0,
"pattern": "api_key_name",
"thresholds": [
""
],
"type": "string",
"unit": "none"
},
{
"alias": "",
"colorMode": null,
"colors": [],
"dateFormat": "YYYY-MM-DD HH:mm:ss",
"decimals": 2,
"pattern": "Time",
"thresholds": [],
"type": "hidden",
"unit": "short"
},
{
"alias": "Request Count",
"colorMode": null,
"colors": [],
"dateFormat": "YYYY-MM-DD HH:mm:ss",
"decimals": 0,
"pattern": "count",
"thresholds": [],
"type": "number",
"unit": "none"
},
{
"alias": "",
"colorMode": null,
"colors": [],
"decimals": 2,
"pattern": "/.*/",
"thresholds": [],
"type": "number",
"unit": "short"
}
],
"targets": [
{
"dsType": "influxdb",
"groupBy": [
{
"params": [
"api_key_name"
],
"type": "tag"
}
],
"measurement": "request_details",
"orderByTime": "ASC",
"policy": "default",
"refId": "A",
"resultFormat": "table",
"select": [
[
{
"params": [
"client_ip"
],
"type": "field"
},
{
"params": [],
"type": "count"
}
]
],
"tags": [
{
"key": "api_key_name",
"operator": "!~",
"value": "/^$definedAPIKey$/"
},
{
"condition": "AND",
"key": "api_key_name",
"operator": "!=",
"value": "unknown"
}
]
}
],
"title": "Total Requests by API Key",
"transform": "table",
"type": "table"
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
},
{
"collapse": false,
"height": 250,
"panels": [
{
"columns": [],
"datasource": "kanali",
Expand Down Expand Up @@ -1603,7 +1833,13 @@
"condition": "AND",
"key": "api_key_name",
"operator": "!=",
"value": "none"
"value": "unknown"
},
{
"condition": "AND",
"key": "api_key_name",
"operator": "!~",
"value": "/^$definedAPIKey$/"
}
]
}
Expand All @@ -1617,7 +1853,7 @@
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "By Proxy",
"title": "Dashboard Row",
"titleSize": "h6"
}
],
Expand Down Expand Up @@ -1717,6 +1953,29 @@
"tagsQuery": "",
"type": "query",
"useTags": false
},
{
"allValue": null,
"current": {
"text": "All",
"value": "$__all"
},
"datasource": "kanali",
"hide": 2,
"includeAll": true,
"label": "",
"multi": false,
"name": "definedAPIKey",
"options": [],
"query": "SHOW TAG VALUES WITH KEY = \"api_key_name\"",
"refresh": 2,
"regex": "/^[A-Za-z0-9]+$/",
"sort": 1,
"tagValuesQuery": "",
"tags": [],
"tagsQuery": "",
"type": "query",
"useTags": false
}
]
},
Expand Down Expand Up @@ -1751,5 +2010,5 @@
},
"timezone": "browser",
"title": "Kanali",
"version": 0
"version": 1
}
Loading

0 comments on commit 8d6eff1

Please sign in to comment.