-
Notifications
You must be signed in to change notification settings - Fork 118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add custom tags to internal metrics #231
Conversation
|
||
// CommonTagsInternal are tags that should be added to all internal metrics | ||
// emitted by the reporter. | ||
CommonTagsInternal map[string]string `yaml:"commonTagsInternal"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you call this InternalTags
or something (i just want the prefix to start with Internal
to make it clear it's for internal usage)
m3/reporter.go
Outdated
@@ -288,6 +289,11 @@ func NewReporter(opts Options) (Reporter, error) { | |||
internalTags := map[string]string{ | |||
"version": tally.Version, | |||
} | |||
|
|||
for k, v := range opts.CommonTagsInternal { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you ensure we don't set host/instance here too please (i think we might be inheriting those from common tags)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Codecov Report
@@ Coverage Diff @@
## master #231 +/- ##
==========================================
+ Coverage 47.82% 47.85% +0.03%
==========================================
Files 64 64
Lines 5989 5993 +4
==========================================
+ Hits 2864 2868 +4
Misses 2685 2685
Partials 440 440
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
0985f9e
to
a5fc9af
Compare
* add custom tags to internal metrics * make unit test stricter, update version
* Set default reporting interval (#226) * Enforce minimum reporting interval * Add new RootScope constructor with default interval * Test with go >= 1.18 (#228) * add custom tags to internal metrics (#231) * add custom tags to internal metrics * make unit test stricter, update version * update version to v3.5.6 --------- Co-authored-by: Vytenis Darulis <vytenis.darulis@chronosphere.io>
No description provided.