qonto / prometheus-rds-exporter

Prometheus exporter for AWS RDS
MIT License
60 stars 10 forks source link

Remove EC2 metrics for serverless deployment #151

Closed vmercierfr closed 5 months ago

vmercierfr commented 5 months ago

Objective

Remove EC2 metrics for serverless deployment

Why

AWS Aurora can be deployed as serverless deployment. Which make the EC2 metrics not relevant and report issues:

{"time":"2024-03-21T12:13:40.256259749Z","level":"ERROR","msg":"can't fetch EC2 metrics: can't fetch describe instance types: operation error EC2: DescribeInstanceTypes, https response error StatusCode: 400, RequestID: b0af5ca9-11a5-47da-b64b-d8187a399999, api error InvalidInstanceType: The following supplied instance types do not exist: [serverless]"}

While we are not (yet) supporting Aurora, we should avoid reaching EC2 metrics for serverless deployments.

How

Release plan

vmercierfr commented 5 months ago

@dcupif I updated the changes with your feedback, can you review it?

github-actions[bot] commented 5 months ago

Code Coverage

Package Line Rate Health
github.com/qonto/prometheus-rds-exporter/internal/app/cloudwatch 87%
github.com/qonto/prometheus-rds-exporter/internal/app/ec2 85%
github.com/qonto/prometheus-rds-exporter/internal/app/exporter 80%
github.com/qonto/prometheus-rds-exporter/internal/app/rds 75%
github.com/qonto/prometheus-rds-exporter/internal/app/servicequotas 51%
github.com/qonto/prometheus-rds-exporter/internal/app/trace 100%
github.com/qonto/prometheus-rds-exporter/internal/app/unit 100%
Summary 80% (1024 / 1284)

Minimum allowed line rate is 60%