Remove actor tag from event metrics across all modules#23
Merged
Conversation
The actor tag causes cardinality explosion in metrics backends since each unique user/actor creates a new time series. Removed from all 12 metric registrations across 7 files: domain event counters, aggregate load counters, translator counters/timers, dispatcher counters/timers, readmodel update counters/timers, provided event counters, and inbound event counters. https://claude.ai/code/session_01HW5m2CmCSTqTMtj5kgdhAV
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This change removes the "actor" tag from all event-related metrics throughout the event modeling framework. The actor field was being extracted from tracing information and used as a metric tag, but is now being removed to simplify metric cardinality and focus on channel-based tracking.
Key Changes
event()andincoming()methods' metrics for domain and inbound eventsImplementation Details
tracing.actor() != null ? tracing.actor() : "unknown") has been completely removed from all locationseventName + ":" + actor + ":" + channel→eventName + ":" + channel)Tags.of()andio.micrometer.core.instrument.Tags.of()callshttps://claude.ai/code/session_01HW5m2CmCSTqTMtj5kgdhAV