guardian / grid

The Guardian’s image management system
https://www.theguardian.com/info/developer-blog/2015/aug/12/open-sourcing-grid-image-service
Apache License 2.0
1.44k stars 119 forks source link

send image loader count metrics both with and WITHOUT the dimension(s) since CloudWatch can't add #4232

Closed twrichards closed 6 months ago

twrichards commented 6 months ago

4230 added a nice dimension for breaking down uploads (successful and failed) by UploadedBy but unfortunately CloudWatch (and therefore also Grafana) can't join/sum these back together 🤦‍ - so we need to send both with and WITHOUT the dimension, which it looks like s3watcher used to do too - see... https://github.com/guardian/grid/blob/5b57ac4dd87b0843a35e074af9841cde78a66875/s3watcher/lambda/lib/Metrics.ts#L19-L31

Also added a further dimension for IsUiUpload (as per suggestion from @dblatcher ) to make it easier to filter out if needs be 🤞

github-actions[bot] commented 6 months ago

Deploy build 12254 to TEST

All deployment options - [Deploy build 12254 to TEST](https://riffraff.gutools.co.uk/deployment/deployAgain?project=media-service%3A%3Agrid%3A%3Aall&build=12254&stage=TEST&updateStrategy=MostlyHarmless&action=deploy) - [Deploy parts of build 12254 to TEST by previewing it first](https://riffraff.gutools.co.uk/preview/yaml?project=media-service%3A%3Agrid%3A%3Aall&build=12254&stage=TEST&updateStrategy=MostlyHarmless)

From guardian/actions-riff-raff.

twrichards commented 6 months ago

Tested in TEST

prout-bot commented 6 months ago

Seen on auth, usage, image-loader, metadata-editor, thrall, leases, cropper, collections, media-api, kahuna (merged by @twrichards 9 minutes and 49 seconds ago) Please check your changes!