Giter Site home page Giter Site logo

sqs-exporter's Introduction

Amazon Simple Queue Service (SQS) Exporter

A Prometheus exporter for the Amazon Simple Queue Service metrics.

Build

docker build --tag sqs-exporter  .

Exported Metrics

Metric Labels
sqs_ATTRIBUTE_NAME Queue Name
  • ApproximateNumberOfMessages - Approximate number of visible messages in a queue. For more information, see Resources Required to Process Messages in the Amazon SQS Developer Guide.
  • ApproximateNumberOfMessagesDelayed - Approximate number of messages that are waiting to be added to the queue.
  • ApproximateNumberOfMessagesNotVisible - Approximate number of messages that have not timed-out and aren't deleted. For more information, see Resources Required to Process Messages in the Amazon SQS Developer Guide.

Configuration

AWS credentials can be provided via the following:

  • Environment Variables - AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY
  • Credentials delivered through the Amazon EC2 container service if AWS_CONTAINER_CREDENTIALS_RELATIVE_URI" environment variable is set and security manager has permission to access the variable,
  • Instance profile credentials delivered through the Amazon EC2 metadata service if running within AWS
  • IAM role applied to either an Amazon Elastic Container Service (ECS) service or task

By default, the exporter will watch all SQS queues visible to the AWS account. To watch a specific set of queues, supply a comma-separated list of queue names in the environment variable SQS_QUEUE_NAMES or a single queue prefix in SQS_QUEUE_NAME_PREFIX. (SQS_QUEUE_NAMES takes precedence over SQS_QUEUE_NAME_PREFIX) (With no parametera specified via environment variables, the full list of queues will be returned)

Docker

You can deploy this exporter using the jmal98/sqs-exporter Docker image.

If you run in AWS, the following will assume it's running with an IAM profile which will allow read access to SQS information.

docker run -d -p 9384:9384 jmal98/sqs-exporter:0.0.6

Use the following to pass the queue filtering environment variables to the docker container.

docker run -d -e SQS_QUEUE_NAME_PREFIX='example_queue_prefix' -p 9384:9384 jmal98/sqs-exporter:0.0.6

If you would like to run the exporter with supplied environment configuration, the following will work both inside and outside of AWS. This is useful if you desire to run the exporter externally.

docker run -d -p 9384:9384 -e AWS_ACCESS_KEY_ID=<access key> -e AWS_SECRET_ACCESS_KEY=<secret key> -e AWS_REGION=<region>  jmal98/sqs-exporter:0.0.6

sqs-exporter's People

Contributors

jmal98 avatar danmaas avatar grahamcookttd avatar grahamcook avatar

Watchers

James Cloos avatar Laurent Rouquette avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.