Skip to content

Proposal: hierarchical metric tag maps in standalone.yml #243

Description

@liaodn

Background

Currently StandaloneStarter only adds a single env common tag to the global registry. In multi-cluster deployments, it would be nice to have more flexible tagging at different levels.

Rough Idea

Introduce a metricsTags map at different levels, something like:

Process-level — global tags for all metrics in the process:

metricsTags:
  region: gz
  deployment: canary

Cluster-level — tags scoped to a specific host-cluster:

agent:
  hostcluster:
    metricsTags:
      cluster: regional-a
      cluster_scope: regional

Subservice propagation — cluster-level tags could also propagate to base-kv, base-rpc, etc.

Thoughts on Precedence

For the same key: process-level < cluster-level < metric-local tags. But this is open for discussion.

Possible Phases

This is quite a bit of scope, so it might make sense to phase it:

  1. Process-level metricsTags
  2. Cluster-level metricsTags under agent.hostcluster
  3. Propagation to base-cluster subservices

Would love to hear thoughts on whether this direction makes sense, and if the naming / precedence / phasing look reasonable.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions