Technofy / cloudwatch_exporter

A CloudWatch exporter for Prometheus coded in Go, with multi-region support
Apache License 2.0
78 stars 140 forks source link

Parallel fetch opto #17

Open tul opened 5 years ago

tul commented 5 years ago

This PR changes the scrapes issued to Cloudwatch to all execute in parallel instead of series. It reduces the scrape time needed hugely in my case, going from just under 60 seconds to scrape 80 metrics to less than a second. This in turn means I can poll more frequently and get higher frequency stats imported from Cloudwatch.

The changes are quite small, I would suggest ignoring whitespace changes whilst viewing the diff.

Thx