Skip to content

Support inserting "collector instance id" as an attribute to spanmetrics metrics #40400

Open
@golopot

Description

@golopot

Component(s)

attributes processor, span metrics connector

Is your feature request related to a problem? Please describe.

It is hard to configure spanmetrics to abide by the single writer principle, in a deployment multiple collectors might export the same metric stream which violates the single writer principle and produces inaccurate metric readings downstream.

This can be solved by attaching a collector instance id attribute to the metric stream, ensuring each collector exports different metrics.

Describe the solution you'd like

Two options:

  1. attributesprocessor: Inserting "collector instance id" attribute to metric streams using attributesprocessor.
  2. spanmetrics: Inserting "collector instance id" attribute to metric streams using spanmetrics connector.

Describe alternatives you've considered

Adding a layer of load balancer collectors with a service.instance.id based routing key. But there are still conflicting metrics writes when you perform a rolling update deployment on collectors. This can be partially solved by setting metrics_expiration for spanmetrics, but still not 100% solved.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions