Skip to content

Instantly share code, notes, and snippets.

@mickey
Created March 20, 2017 18:20
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mickey/cc0de597b763e40f4f8acff5b75b6858 to your computer and use it in GitHub Desktop.
Save mickey/cc0de597b763e40f4f8acff5b75b6858 to your computer and use it in GitHub Desktop.
{
"annotations": {
"list": []
},
"editable": true,
"gnetId": null,
"graphTooltip": 0,
"hideControls": false,
"id": 22,
"links": [],
"refresh": "30s",
"rows": [
{
"collapse": false,
"height": 43,
"panels": [
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "Influxdb",
"editable": true,
"error": false,
"format": "none",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 3,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": "",
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 4,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": true,
"lineColor": "rgb(31, 120, 193)",
"show": true
},
"targets": [
{
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$period"
],
"type": "time"
},
{
"params": [
"null"
],
"type": "fill"
}
],
"measurement": "sidekiq",
"policy": "a_year",
"query": "SELECT mean(\"value\") FROM \"measurement\" WHERE $timeFilter GROUP BY time($interval) fill(null)",
"rawQuery": false,
"refId": "A",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"count"
],
"type": "field"
},
{
"params": [],
"type": "sum"
},
{
"params": [],
"type": "cumulative_sum"
}
]
],
"tags": [
{
"key": "env",
"operator": "=~",
"value": "/^$environment$/"
},
{
"condition": "AND",
"key": "queue",
"operator": "=~",
"value": "/^$queue$/"
},
{
"condition": "AND",
"key": "worker",
"operator": "=~",
"value": "/^$job$/"
}
],
"target": "integral(counters.drivy-rails.production.jobs.urgent_fast.Drivy-Filters-SaveFromSearchParams.count.count)",
"textEditor": false
}
],
"thresholds": "",
"title": "Total",
"type": "singlestat",
"valueFontSize": "200%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "current"
},
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "Influxdb",
"editable": true,
"error": false,
"format": "none",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 9,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": "",
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 4,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": true,
"lineColor": "rgb(31, 120, 193)",
"show": true
},
"targets": [
{
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$period"
],
"type": "time"
},
{
"params": [
"null"
],
"type": "fill"
}
],
"measurement": "sidekiq",
"policy": "a_year",
"query": "SELECT mean(\"value\") FROM \"measurement\" WHERE $timeFilter GROUP BY time($interval) fill(null)",
"rawQuery": false,
"refId": "A",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"success"
],
"type": "field"
},
{
"params": [],
"type": "sum"
},
{
"params": [],
"type": "cumulative_sum"
}
]
],
"tags": [
{
"key": "env",
"operator": "=~",
"value": "/^$environment$/"
},
{
"condition": "AND",
"key": "queue",
"operator": "=~",
"value": "/^$queue$/"
},
{
"condition": "AND",
"key": "worker",
"operator": "=~",
"value": "/^$job$/"
}
],
"target": "integral(counters.drivy-rails.production.jobs.urgent_fast.Drivy-Filters-SaveFromSearchParams.count.count)",
"textEditor": false
}
],
"thresholds": "",
"title": "Success",
"type": "singlestat",
"valueFontSize": "200%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "current"
},
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "Influxdb",
"editable": true,
"error": false,
"format": "none",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 10,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": "",
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 4,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": true,
"lineColor": "rgb(31, 120, 193)",
"show": true
},
"targets": [
{
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$period"
],
"type": "time"
},
{
"params": [
"null"
],
"type": "fill"
}
],
"measurement": "sidekiq",
"policy": "a_year",
"query": "SELECT mean(\"value\") FROM \"measurement\" WHERE $timeFilter GROUP BY time($interval) fill(null)",
"rawQuery": false,
"refId": "A",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"failure"
],
"type": "field"
},
{
"params": [],
"type": "sum"
},
{
"params": [],
"type": "cumulative_sum"
}
]
],
"tags": [
{
"key": "env",
"operator": "=~",
"value": "/^$environment$/"
},
{
"condition": "AND",
"key": "queue",
"operator": "=~",
"value": "/^$queue$/"
},
{
"condition": "AND",
"key": "worker",
"operator": "=~",
"value": "/^$job$/"
}
],
"target": "integral(counters.drivy-rails.production.jobs.urgent_fast.Drivy-Filters-SaveFromSearchParams.count.count)",
"textEditor": false
}
],
"thresholds": "",
"title": "Failure",
"type": "singlestat",
"valueFontSize": "200%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "current"
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
},
{
"collapse": false,
"height": 246,
"panels": [
{
"aliasColors": {},
"bars": false,
"datasource": "Influxdb",
"editable": true,
"error": false,
"fill": 1,
"id": 1,
"legend": {
"alignAsTable": false,
"avg": false,
"current": false,
"hideEmpty": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"maxDataPoints": "",
"nullPointMode": "null as zero",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"span": 4,
"stack": false,
"steppedLine": false,
"targets": [
{
"alias": "Count",
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$period"
],
"type": "time"
},
{
"params": [
"0"
],
"type": "fill"
}
],
"measurement": "sidekiq",
"policy": "a_year",
"refId": "A",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"count"
],
"type": "field"
},
{
"params": [],
"type": "sum"
}
]
],
"tags": [
{
"key": "env",
"operator": "=~",
"value": "/^$environment$/"
},
{
"condition": "AND",
"key": "queue",
"operator": "=~",
"value": "/^$queue$/"
},
{
"condition": "AND",
"key": "worker",
"operator": "=~",
"value": "/^$job$/"
}
],
"target": "hitcount(transformNull(counters.drivy-rails.$environment.jobs.$queue_name.$job_name.count.count, 0), '1h')",
"textEditor": false
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "Jobs Count",
"tooltip": {
"msResolution": false,
"shared": false,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"mode": "time",
"name": null,
"show": true,
"values": [
"total"
]
},
"yaxes": [
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
},
{
"aliasColors": {},
"bars": false,
"datasource": "Influxdb",
"editable": true,
"error": false,
"fill": 1,
"id": 2,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "connected",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"span": 8,
"stack": false,
"steppedLine": false,
"targets": [
{
"alias": "Average",
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$period"
],
"type": "time"
},
{
"params": [
"0"
],
"type": "fill"
}
],
"hide": false,
"measurement": "sidekiq",
"policy": "a_year",
"refId": "A",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"perform"
],
"type": "field"
},
{
"params": [],
"type": "mean"
}
]
],
"tags": [
{
"key": "env",
"operator": "=~",
"value": "/^$environment$/"
},
{
"condition": "AND",
"key": "queue",
"operator": "=~",
"value": "/^$queue$/"
},
{
"condition": "AND",
"key": "worker",
"operator": "=~",
"value": "/^$job$/"
}
]
},
{
"alias": "99th percentile",
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$period"
],
"type": "time"
},
{
"params": [
"0"
],
"type": "fill"
}
],
"hide": false,
"measurement": "sidekiq",
"policy": "a_year",
"refId": "B",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"perform"
],
"type": "field"
},
{
"params": [
"99"
],
"type": "percentile"
}
]
],
"tags": [
{
"key": "env",
"operator": "=~",
"value": "/^$environment$/"
},
{
"condition": "AND",
"key": "queue",
"operator": "=~",
"value": "/^$queue$/"
},
{
"condition": "AND",
"key": "worker",
"operator": "=~",
"value": "/^$job$/"
}
]
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "Jobs Times",
"tooltip": {
"msResolution": false,
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "ms",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
},
{
"collapse": false,
"height": 250,
"panels": [
{
"aliasColors": {},
"bars": false,
"datasource": "Influxdb",
"editable": true,
"error": false,
"fill": 1,
"id": 6,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "connected",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"span": 12,
"stack": false,
"steppedLine": false,
"targets": [
{
"alias": "Average",
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$period"
],
"type": "time"
},
{
"params": [
"0"
],
"type": "fill"
}
],
"measurement": "sidekiq",
"policy": "a_year",
"refId": "C",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"enqueued_for"
],
"type": "field"
},
{
"params": [],
"type": "mean"
}
]
],
"tags": [
{
"key": "env",
"operator": "=~",
"value": "/^$environment$/"
},
{
"condition": "AND",
"key": "queue",
"operator": "=~",
"value": "/^$queue$/"
},
{
"condition": "AND",
"key": "worker",
"operator": "=~",
"value": "/^$job$/"
}
],
"target": "alias(maxSeries(summarize(timers.drivy-rails.$environment.jobs.$queue_name.$job_name.enqueued_for.upper, '$interval', 'max', false)), 'Max')",
"textEditor": false
},
{
"alias": "95th percentile",
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$period"
],
"type": "time"
},
{
"params": [
"0"
],
"type": "fill"
}
],
"measurement": "sidekiq",
"policy": "a_year",
"refId": "A",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"enqueued_for"
],
"type": "field"
},
{
"params": [
"99"
],
"type": "percentile"
}
]
],
"tags": [
{
"key": "env",
"operator": "=~",
"value": "/^$environment$/"
},
{
"condition": "AND",
"key": "queue",
"operator": "=~",
"value": "/^$queue$/"
},
{
"condition": "AND",
"key": "worker",
"operator": "=~",
"value": "/^$job$/"
}
],
"target": "alias(maxSeries(summarize(timers.drivy-rails.$environment.jobs.$queue_name.$job_name.enqueued_for.upper, '$interval', 'max', false)), 'Max')",
"textEditor": false
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "Average Enqueue Time",
"tooltip": {
"msResolution": false,
"shared": true,
"sort": 2,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "ms",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
},
{
"collapse": false,
"height": 250,
"panels": [
{
"columns": [
{
"text": "Avg",
"value": "avg"
},
{
"text": "Max",
"value": "max"
}
],
"datasource": "Influxdb",
"editable": true,
"error": false,
"fontSize": "100%",
"id": 7,
"links": [],
"pageSize": null,
"scroll": true,
"showHeader": true,
"sort": {
"col": 1,
"desc": false
},
"span": 12,
"styles": [
{
"dateFormat": "YYYY-MM-DD HH:mm:ss",
"pattern": "Time",
"type": "date"
},
{
"colorMode": null,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"decimals": 2,
"pattern": "/(Max|Avg)/",
"thresholds": [],
"type": "number",
"unit": "ms"
}
],
"targets": [
{
"alias": "$tag_worker",
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$period"
],
"type": "time"
},
{
"params": [
"worker"
],
"type": "tag"
},
{
"params": [
"0"
],
"type": "fill"
}
],
"measurement": "sidekiq",
"policy": "a_year",
"refId": "A",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"perform"
],
"type": "field"
},
{
"params": [],
"type": "mean"
}
]
],
"tags": [
{
"key": "worker",
"operator": "=~",
"value": "/^$job$/"
},
{
"condition": "AND",
"key": "env",
"operator": "=~",
"value": "/^$environment$/"
},
{
"condition": "AND",
"key": "queue",
"operator": "=~",
"value": "/^$queue$/"
}
],
"target": "maximumAbove(groupByNode(drivy-rails.$environment.jobs.$queue_name.$job_name.perform.50_percentile.timing, 4, 'avg'), 0)"
}
],
"title": "Times per job",
"transform": "timeseries_aggregations",
"type": "table"
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
}
],
"schemaVersion": 14,
"style": "dark",
"tags": [
"influxdb"
],
"templating": {
"list": [
{
"allValue": null,
"current": {
"text": "production",
"value": "production"
},
"datasource": "Influxdb",
"hide": 0,
"includeAll": false,
"label": "Environment",
"multi": false,
"name": "environment",
"options": [],
"query": "SHOW TAG VALUES FROM \"sidekiq\" WITH KEY = \"env\"",
"refresh": 2,
"regex": "",
"sort": 0,
"tagValuesQuery": null,
"tags": [],
"tagsQuery": null,
"type": "query",
"useTags": false
},
{
"allValue": null,
"current": {
"text": "All",
"value": [
"$__all"
]
},
"datasource": "Influxdb",
"hide": 0,
"includeAll": true,
"label": "Queue",
"multi": true,
"name": "queue",
"options": [],
"query": "SHOW TAG VALUES FROM \"sidekiq\" WITH KEY = \"queue\"",
"refresh": 2,
"regex": "",
"sort": 1,
"tagValuesQuery": null,
"tags": [],
"tagsQuery": null,
"type": "query",
"useTags": false
},
{
"allValue": null,
"current": {
"text": "All",
"value": "$__all"
},
"datasource": "Influxdb",
"hide": 0,
"includeAll": true,
"label": "Job",
"multi": false,
"name": "job",
"options": [],
"query": "SHOW TAG VALUES FROM \"sidekiq\" WITH KEY = \"worker\"",
"refresh": 2,
"regex": "",
"sort": 0,
"tagValuesQuery": null,
"tags": [],
"tagsQuery": null,
"type": "query",
"useTags": false
},
{
"auto": true,
"auto_count": 30,
"auto_min": "10s",
"current": {
"text": "auto",
"value": "$__auto_interval"
},
"hide": 0,
"label": "Period",
"name": "period",
"options": [
{
"selected": true,
"text": "auto",
"value": "$__auto_interval"
},
{
"selected": false,
"text": "30s",
"value": "30s"
},
{
"selected": false,
"text": "1m",
"value": "1m"
},
{
"selected": false,
"text": "5m",
"value": "5m"
},
{
"selected": false,
"text": "10m",
"value": "10m"
},
{
"selected": false,
"text": "30m",
"value": "30m"
},
{
"selected": false,
"text": "1h",
"value": "1h"
},
{
"selected": false,
"text": "3h",
"value": "3h"
},
{
"selected": false,
"text": "6h",
"value": "6h"
},
{
"selected": false,
"text": "12h",
"value": "12h"
},
{
"selected": false,
"text": "1d",
"value": "1d"
},
{
"selected": false,
"text": "7d",
"value": "7d"
},
{
"selected": false,
"text": "14d",
"value": "14d"
},
{
"selected": false,
"text": "30d",
"value": "30d"
}
],
"query": "30s,1m,5m,10m,30m,1h,3h,6h,12h,1d,7d,14d,30d",
"refresh": 2,
"type": "interval"
}
]
},
"time": {
"from": "now-24h",
"to": "now"
},
"timepicker": {
"refresh_intervals": [
"5s",
"10s",
"30s",
"1m",
"5m",
"15m",
"30m",
"1h",
"2h",
"1d"
],
"time_options": [
"5m",
"15m",
"1h",
"6h",
"12h",
"24h",
"2d",
"7d",
"30d"
]
},
"timezone": "utc",
"title": "Jobs",
"version": 44
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment