Originally reported here: #4956 (review) by @cyrille-leclerc
The spec currently has:
|
| OTLP Resource Attribute | Description | |
|
| ----------------------- | ----------- | |
|
| `server.address` | The `<host>` portion of the target's URL that was scraped | |
|
| `server.port` | The `<port>` portion of the target's URL that was scraped | |
|
| `url.scheme` | `http` or `https` | |
This adds resource attributes to scraped metrics based on the endpoint they are scraped from. However, metrics themselves may have their own server.address label.
We should consider:
- Migrating to prometheus.server.address, prometheus.server.port, and prometheus.url.scheme. This would prevent collisions, while avoiding breaking users too much.
- Not setting those resource attributes at all. Resource attributes should describe the resource being monitored, not how they are transmitted to the destination. For example, we don't add the OTLP port used when sending OTLP to a collector. Why should scraping be different?
Originally reported here: #4956 (review) by @cyrille-leclerc
The spec currently has:
opentelemetry-specification/specification/compatibility/prometheus_and_openmetrics.md
Lines 393 to 397 in efceef7
This adds resource attributes to scraped metrics based on the endpoint they are scraped from. However, metrics themselves may have their own server.address label.
We should consider: