What is Prometheus?
Prometheus is an open-source system monitoring and alerting tool kit with strong open-source client library support for languages such as Java, Go, C#, Python, Node JS, etc. It records real-time metrics in a time series database built using an HTTP pull model, with flexible queries and real-time alerting. It is a Multidimensional data model presenting time series data.
Challenges in Prometheus
- Managing Storage, API availability, and Scalability
- A lot of being spent on optimizing memory and compressing storage to reduce costs and improve query response times
- Iterative work in the building, patching and upgrading Prometheus servers
- Implementing governance policies to enforce authorization on Querying and collecting metrics
Amazon Managed Service for Prometheus (AMP)
Amazon Managed Service for Prometheus (AMP) is a Serverless, compatible monitoring service tool to securely monitor container environments. AMP uses the same open-source Prometheus data model to monitor the performance of containerized workloads. In addition, AMP with Cortex adds horizontal scalability to ingest, store, and query Prometheus metrics. AMP reduces the load required to start monitoring applications across Container Service, and Kubernetes services in Amazon.
- AMP offers highly-available, multi-zone deployments, and integrates AWS security and compliance capabilities
- AMP offers native support for the PromQL query language as well as over 150+ Prometheus exporters maintained by the open-source community
- No upfront investments are required for using the service and customers only pay for the metrics
- AMP also supports rules and alerts managers
- AMP also uses AWS Distro for OpenTelemetry which acts as a collection agent for Prometheus metrics
Amazon Managed Prometheus Architecture
Metrics Collectors
Metric collectors (such as a Prometheus server deployed to an Amazon EKS cluster) pull the operational metrics from containerized workloads running in the cluster and send them to AMP for long-term storage as well as for querying metrics by using monitoring tools. We can use an OpenTelemetry agent such as the AWS Distro for OpenTelemetry Collector.
Setting up a Workspace to Collect Prometheus Metrics
A workspace is a logical container where you ingest, store, and query your Prometheus metrics, collected from application workloads. In each region, one or more workspaces may be created within the same AWS account. Each workspace can be used to ingest metrics from multiple workloads that export metrics in Prometheus-compatible format.
Visualizing Metrics using Grafana
Amazon Managed Prometheus Workspace metrics can be integrated and visualized using Grafana/Amazon Managed Grafana in the form of Graphs, Bar charts, Plugins, Tables, Logs, Texts, etc.
Using Amazon Managed Service for Prometheus, clients can work on cloud-based monitoring rearranged for container-based apps without building, scaling, or maintaining Prometheus. AWS announced Amazon Managed Prometheus (AMP) in December 2020 during re: Invent and extending its services throughout the world.