Description
Description of the Problem/Issue
When publishing metrics, it's would be useful to be able to reference the specific values that generated the specific metric value.
For example, in one project I'm crawling some URLs. In this case I log the size of the fetched object as a metric. Being able to annotate that metric (add_property in the aws-embedded-metrics-python library) with the URL it's very useful when doing insights after. If I rely on Tracing info, this means I depend on xray and also will be affected by sampling.
Logging this in a structured logging, will separate the information from the metric, so parsing the logs will be much harder, so being able to add this info along with the metric publishing would be useful.
Describe the solution you'd like
Add an add_metadata or add_property method to metrics similar to the one found in aws-embedded-metrics-python
Describe alternatives you've considered
- Using Tracing - not useful due to:
- Depend on Xray for reading the info
- Will be affected by sampling
- Using Logging - not useful due to complexity when querying the logs. Also, if this info is recorded at Debug level, lot of other info will be also published which probably is not the intention. The same at any other level.