---
apiVersion: v1
kind: ConfigMap
metadata:
  name: dashboard-datasource-sqs
  namespace: monitoring
  labels:
    grafana_dashboard: ""
data:
  datasource-sqs-dashboard.json: |
    {
      "annotations": {
        "list": [
          {
            "builtIn": 1,
            "datasource": "-- Grafana --",
            "enable": true,
            "hide": true,
            "iconColor": "rgba(0, 211, 255, 1)",
            "name": "Annotations & Alerts",
            "type": "dashboard"
          }
        ]
      },
      "description": "Visualize AWS SQS metrics",
      "editable": false,
      "gnetId": 584,
      "graphTooltip": 0,
      "id": 13,
      "iteration": 1581609638673,
      "links": [],
      "panels": [
        {
          "aliasColors": {},
          "bars": false,
          "dashLength": 10,
          "dashes": false,
          "datasource": "${datasource}",
          "editable": true,
          "error": false,
          "fill": 1,
          "fillGradient": 0,
          "grid": {},
          "gridPos": {
            "h": 8,
            "w": 24,
            "x": 0,
            "y": 0
          },
          "hiddenSeries": false,
          "id": 7,
          "isNew": true,
          "legend": {
            "alignAsTable": true,
            "avg": true,
            "current": true,
            "max": true,
            "min": true,
            "show": true,
            "sort": "current",
            "sortDesc": true,
            "total": false,
            "values": true
          },
          "lines": true,
          "linewidth": 2,
          "links": [],
          "nullPointMode": "connected",
          "options": {
            "dataLinks": []
          },
          "percentage": false,
          "pointradius": 5,
          "points": false,
          "renderer": "flot",
          "seriesOverrides": [],
          "spaceLength": 10,
          "stack": false,
          "steppedLine": false,
          "targets": [
            {
              "alias": "",
              "application": {
                "filter": ""
              },
              "dimensions": {
                "QueueName": "$queue"
              },
              "functions": [],
              "group": {
                "filter": ""
              },
              "host": {
                "filter": ""
              },
              "item": {
                "filter": ""
              },
              "metricName": "NumberOfMessagesDeleted",
              "mode": 0,
              "namespace": "AWS/SQS",
              "options": {
                "showDisabledItems": false
              },
              "period": "",
              "refId": "A",
              "region": "$region",
              "statistics": [
                "Average"
              ]
            },
            {
              "alias": "",
              "application": {
                "filter": ""
              },
              "dimensions": {
                "QueueName": "$queue"
              },
              "functions": [],
              "group": {
                "filter": ""
              },
              "host": {
                "filter": ""
              },
              "item": {
                "filter": ""
              },
              "metricName": "NumberOfMessagesReceived",
              "mode": 0,
              "namespace": "AWS/SQS",
              "options": {
                "showDisabledItems": false
              },
              "period": "",
              "refId": "B",
              "region": "$region",
              "statistics": [
                "Average"
              ]
            },
            {
              "alias": "",
              "application": {
                "filter": ""
              },
              "dimensions": {
                "QueueName": "$queue"
              },
              "functions": [],
              "group": {
                "filter": ""
              },
              "host": {
                "filter": ""
              },
              "item": {
                "filter": ""
              },
              "metricName": "NumberOfMessagesSent",
              "mode": 0,
              "namespace": "AWS/SQS",
              "options": {
                "showDisabledItems": false
              },
              "period": "",
              "refId": "C",
              "region": "$region",
              "statistics": [
                "Average"
              ]
            }
          ],
          "thresholds": [],
          "timeFrom": null,
          "timeRegions": [],
          "timeShift": null,
          "title": "Messages",
          "tooltip": {
            "msResolution": false,
            "shared": true,
            "sort": 0,
            "value_type": "cumulative"
          },
          "type": "graph",
          "xaxis": {
            "buckets": null,
            "mode": "time",
            "name": null,
            "show": true,
            "values": []
          },
          "yaxes": [
            {
              "format": "none",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": 0,
              "show": true
            },
            {
              "format": "short",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": null,
              "show": false
            }
          ],
          "yaxis": {
            "align": false,
            "alignLevel": null
          }
        },
        {
          "aliasColors": {},
          "bars": false,
          "dashLength": 10,
          "dashes": false,
          "datasource": "${datasource}",
          "editable": true,
          "error": false,
          "fill": 1,
          "fillGradient": 0,
          "grid": {},
          "gridPos": {
            "h": 7,
            "w": 24,
            "x": 0,
            "y": 8
          },
          "hiddenSeries": false,
          "id": 1,
          "isNew": true,
          "legend": {
            "alignAsTable": true,
            "avg": true,
            "current": true,
            "max": true,
            "min": true,
            "show": true,
            "sort": "current",
            "sortDesc": true,
            "total": false,
            "values": true
          },
          "lines": true,
          "linewidth": 2,
          "links": [],
          "nullPointMode": "connected",
          "options": {
            "dataLinks": []
          },
          "percentage": false,
          "pointradius": 5,
          "points": false,
          "renderer": "flot",
          "seriesOverrides": [],
          "spaceLength": 10,
          "stack": false,
          "steppedLine": false,
          "targets": [
            {
              "alias": "",
              "application": {
                "filter": ""
              },
              "dimensions": {
                "QueueName": "$queue"
              },
              "functions": [],
              "group": {
                "filter": ""
              },
              "host": {
                "filter": ""
              },
              "item": {
                "filter": ""
              },
              "metricName": "ApproximateAgeOfOldestMessage",
              "mode": 0,
              "namespace": "AWS/SQS",
              "options": {
                "showDisabledItems": false
              },
              "period": "",
              "refId": "A",
              "region": "$region",
              "statistics": [
                "Average"
              ]
            }
          ],
          "thresholds": [],
          "timeFrom": null,
          "timeRegions": [],
          "timeShift": null,
          "title": "ApproximateAgeOfOldestMessage",
          "tooltip": {
            "msResolution": false,
            "shared": true,
            "sort": 0,
            "value_type": "cumulative"
          },
          "type": "graph",
          "xaxis": {
            "buckets": null,
            "mode": "time",
            "name": null,
            "show": true,
            "values": []
          },
          "yaxes": [
            {
              "format": "s",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": 0,
              "show": true
            },
            {
              "format": "short",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": null,
              "show": false
            }
          ],
          "yaxis": {
            "align": false,
            "alignLevel": null
          }
        },
        {
          "aliasColors": {},
          "bars": false,
          "dashLength": 10,
          "dashes": false,
          "datasource": "${datasource}",
          "editable": true,
          "error": false,
          "fill": 1,
          "fillGradient": 0,
          "grid": {},
          "gridPos": {
            "h": 7,
            "w": 24,
            "x": 0,
            "y": 15
          },
          "hiddenSeries": false,
          "id": 4,
          "isNew": true,
          "legend": {
            "alignAsTable": true,
            "avg": true,
            "current": true,
            "max": true,
            "min": true,
            "show": true,
            "sort": "current",
            "sortDesc": true,
            "total": false,
            "values": true
          },
          "lines": true,
          "linewidth": 2,
          "links": [],
          "nullPointMode": "connected",
          "options": {
            "dataLinks": []
          },
          "percentage": false,
          "pointradius": 5,
          "points": false,
          "renderer": "flot",
          "seriesOverrides": [],
          "spaceLength": 10,
          "stack": false,
          "steppedLine": false,
          "targets": [
            {
              "alias": "",
              "application": {
                "filter": ""
              },
              "dimensions": {
                "QueueName": "$queue"
              },
              "functions": [],
              "group": {
                "filter": ""
              },
              "host": {
                "filter": ""
              },
              "item": {
                "filter": ""
              },
              "metricName": "ApproximateNumberOfMessagesVisible",
              "mode": 0,
              "namespace": "AWS/SQS",
              "options": {
                "showDisabledItems": false
              },
              "period": "",
              "refId": "C",
              "region": "$region",
              "statistics": [
                "Average"
              ]
            },
            {
              "alias": "",
              "application": {
                "filter": ""
              },
              "dimensions": {
                "QueueName": "$queue"
              },
              "functions": [],
              "group": {
                "filter": ""
              },
              "host": {
                "filter": ""
              },
              "item": {
                "filter": ""
              },
              "metricName": "ApproximateNumberOfMessagesNotVisible",
              "mode": 0,
              "namespace": "AWS/SQS",
              "options": {
                "showDisabledItems": false
              },
              "period": "",
              "refId": "A",
              "region": "$region",
              "statistics": [
                "Average"
              ]
            },
            {
              "alias": "",
              "application": {
                "filter": ""
              },
              "dimensions": {
                "QueueName": "$queue"
              },
              "functions": [],
              "group": {
                "filter": ""
              },
              "host": {
                "filter": ""
              },
              "item": {
                "filter": ""
              },
              "metricName": "ApproximateNumberOfMessagesDelayed",
              "mode": 0,
              "namespace": "AWS/SQS",
              "options": {
                "showDisabledItems": false
              },
              "period": "",
              "refId": "B",
              "region": "$region",
              "statistics": [
                "Average"
              ]
            }
          ],
          "thresholds": [],
          "timeFrom": null,
          "timeRegions": [],
          "timeShift": null,
          "title": "ApproximateNumberOfMessages",
          "tooltip": {
            "msResolution": false,
            "shared": true,
            "sort": 0,
            "value_type": "cumulative"
          },
          "type": "graph",
          "xaxis": {
            "buckets": null,
            "mode": "time",
            "name": null,
            "show": true,
            "values": []
          },
          "yaxes": [
            {
              "format": "none",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": 0,
              "show": true
            },
            {
              "format": "short",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": null,
              "show": false
            }
          ],
          "yaxis": {
            "align": false,
            "alignLevel": null
          }
        },
        {
          "aliasColors": {},
          "bars": false,
          "dashLength": 10,
          "dashes": false,
          "datasource": "${datasource}",
          "editable": true,
          "error": false,
          "fill": 1,
          "fillGradient": 0,
          "grid": {},
          "gridPos": {
            "h": 7,
            "w": 24,
            "x": 0,
            "y": 22
          },
          "hiddenSeries": false,
          "id": 6,
          "isNew": true,
          "legend": {
            "alignAsTable": true,
            "avg": true,
            "current": true,
            "max": true,
            "min": true,
            "show": true,
            "sort": "current",
            "sortDesc": true,
            "total": false,
            "values": true
          },
          "lines": true,
          "linewidth": 2,
          "links": [],
          "nullPointMode": "connected",
          "options": {
            "dataLinks": []
          },
          "percentage": false,
          "pointradius": 5,
          "points": false,
          "renderer": "flot",
          "seriesOverrides": [],
          "spaceLength": 10,
          "stack": false,
          "steppedLine": false,
          "targets": [
            {
              "alias": "",
              "application": {
                "filter": ""
              },
              "dimensions": {
                "QueueName": "$queue"
              },
              "functions": [],
              "group": {
                "filter": ""
              },
              "host": {
                "filter": ""
              },
              "item": {
                "filter": ""
              },
              "metricName": "NumberOfEmptyReceives",
              "mode": 0,
              "namespace": "AWS/SQS",
              "options": {
                "showDisabledItems": false
              },
              "period": "",
              "refId": "A",
              "region": "$region",
              "statistics": [
                "Average"
              ]
            }
          ],
          "thresholds": [],
          "timeFrom": null,
          "timeRegions": [],
          "timeShift": null,
          "title": "NumberOfEmptyReceives",
          "tooltip": {
            "msResolution": false,
            "shared": true,
            "sort": 0,
            "value_type": "cumulative"
          },
          "type": "graph",
          "xaxis": {
            "buckets": null,
            "mode": "time",
            "name": null,
            "show": true,
            "values": []
          },
          "yaxes": [
            {
              "format": "none",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": 0,
              "show": true
            },
            {
              "format": "short",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": null,
              "show": false
            }
          ],
          "yaxis": {
            "align": false,
            "alignLevel": null
          }
        },
        {
          "aliasColors": {},
          "bars": false,
          "dashLength": 10,
          "dashes": false,
          "datasource": "${datasource}",
          "editable": true,
          "error": false,
          "fill": 1,
          "fillGradient": 0,
          "grid": {},
          "gridPos": {
            "h": 7,
            "w": 24,
            "x": 0,
            "y": 29
          },
          "hiddenSeries": false,
          "id": 10,
          "isNew": true,
          "legend": {
            "alignAsTable": true,
            "avg": true,
            "current": true,
            "max": true,
            "min": true,
            "show": true,
            "sort": "current",
            "sortDesc": true,
            "total": false,
            "values": true
          },
          "lines": true,
          "linewidth": 2,
          "links": [],
          "nullPointMode": "connected",
          "options": {
            "dataLinks": []
          },
          "percentage": false,
          "pointradius": 5,
          "points": false,
          "renderer": "flot",
          "seriesOverrides": [],
          "spaceLength": 10,
          "stack": false,
          "steppedLine": false,
          "targets": [
            {
              "alias": "",
              "application": {
                "filter": ""
              },
              "dimensions": {
                "QueueName": "$queue"
              },
              "functions": [],
              "group": {
                "filter": ""
              },
              "host": {
                "filter": ""
              },
              "item": {
                "filter": ""
              },
              "metricName": "SentMessageSize",
              "mode": 0,
              "namespace": "AWS/SQS",
              "options": {
                "showDisabledItems": false
              },
              "period": "",
              "refId": "A",
              "region": "$region",
              "statistics": [
                "Average"
              ]
            }
          ],
          "thresholds": [],
          "timeFrom": null,
          "timeRegions": [],
          "timeShift": null,
          "title": "SentMessageSize",
          "tooltip": {
            "msResolution": false,
            "shared": true,
            "sort": 0,
            "value_type": "cumulative"
          },
          "type": "graph",
          "xaxis": {
            "buckets": null,
            "mode": "time",
            "name": null,
            "show": true,
            "values": []
          },
          "yaxes": [
            {
              "format": "bytes",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": 0,
              "show": true
            },
            {
              "format": "short",
              "label": null,
              "logBase": 1,
              "max": null,
              "min": null,
              "show": false
            }
          ],
          "yaxis": {
            "align": false,
            "alignLevel": null
          }
        },
        {
          "content": "<a style=\"float: right\" href=\"http://www.monitoringartist.com\" target=\"_blank\" title=\"Dashboard maintained by Monitoring Artist - DevOps / Docker / Kubernetes / AWS ECS / Google GCP / Zabbix / Zenoss / Terraform / Monitoring\"><img src=\"https://monitoringartist.github.io/monitoring-artist-logo-grafana.png\" height=\"30px\" /></a>\n<a style=\"float: left\"  target=\"_blank\" href=\"http://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/sqs-metricscollected.html\">AWS CloudWatch SQS documentation</a><br/>\n<a style=\"float: left\"  target=\"_blank\" href=\"https://grafana.com/dashboards/584\">Installed from Grafana.com dashboards</a>\n<div style=\"clear:both; width:100%;height:0;font-size:0;\"></div>",
          "datasource": null,
          "editable": true,
          "error": false,
          "gridPos": {
            "h": 3,
            "w": 24,
            "x": 0,
            "y": 36
          },
          "id": 2,
          "isNew": true,
          "links": [],
          "mode": "html",
          "options": {},
          "title": "Documentation",
          "type": "text"
        }
      ],
      "refresh": false,
      "schemaVersion": 21,
      "style": "dark",
      "tags": [
        "monitoringartist",
        "cloudwatch"
      ],
      "templating": {
        "list": [
          {
            "current": {
              "tags": [],
              "text": "Cloudwatch-Datasource",
              "value": "Cloudwatch-Datasource"
            },
            "hide": 0,
            "includeAll": false,
            "label": "Datasource",
            "multi": false,
            "name": "datasource",
            "options": [],
            "query": "cloudwatch",
            "refresh": 1,
            "regex": "",
            "skipUrlSync": false,
            "type": "datasource"
          },
          {
            "allValue": null,
            "current": {
              "text": "default",
              "value": "default"
            },
            "datasource": "${datasource}",
            "definition": "",
            "hide": 0,
            "includeAll": false,
            "label": "Region",
            "multi": false,
            "name": "region",
            "options": [],
            "query": "regions()",
            "refresh": 1,
            "regex": "",
            "skipUrlSync": false,
            "sort": 0,
            "tagValuesQuery": "",
            "tags": [],
            "tagsQuery": "",
            "type": "query",
            "useTags": false
          },
          {
            "allValue": null,
            "current": {
              "text": "Digital-Prison-Services-dev-case_note_poll_pusher_queue",
              "value": "Digital-Prison-Services-dev-case_note_poll_pusher_queue"
            },
            "datasource": "${datasource}",
            "definition": "",
            "hide": 0,
            "includeAll": false,
            "label": "Queue name",
            "multi": false,
            "name": "queue",
            "options": [],
            "query": "dimension_values($region,AWS/SQS,NumberOfMessagesReceived,QueueName)",
            "refresh": 1,
            "regex": "",
            "skipUrlSync": false,
            "sort": 0,
            "tagValuesQuery": "",
            "tags": [],
            "tagsQuery": "",
            "type": "query",
            "useTags": false
          }
        ]
      },
      "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": "browser",
      "title": "AWS SQS",
      "uid": "AWSSQS000",
      "version": 1
    }