Skip to content
This repository has been archived by the owner on Aug 30, 2019. It is now read-only.

Misc improvements #325

Merged
merged 3 commits into from
Oct 20, 2017
Merged

Misc improvements #325

merged 3 commits into from
Oct 20, 2017

Conversation

LotharSee
Copy link

  • use a different metric tag to count traces manually prioritized
  • fix multiline logging
  • expire receiverStats tagset

Example of previous output: multi-line, one tag set.

2017-10-12 12:19:39 INFO (receiver.go:316) -
        [lang:go lang_version:1.9.1 interpreter:gc-amd64-linux tracer_version:v0.5.0] -> traces received: 21358, traces dropped: 0, traces filtered: 0, traces amount: 14167935 bytes, services received: 0, services amount: 0 bytes
        [] -> traces received: 0, traces dropped: 0, traces filtered: 0, traces amount: 0 bytes, services received: 0, services amount: 0 bytes

After this PR, is should simply look like:

2017-10-12 12:19:39 INFO (receiver.go:316) - [lang:go lang_version:1.9.1 interpreter:gc-amd64-linux tracer_version:v0.5.0] -> traces received: 21358, traces dropped: 0, traces filtered: 0, traces amount: 14167935 bytes, services received: 0, services amount: 0 bytes

Copy link

@ufoot ufoot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good for me.

for key, tagStats := range rs.Stats {
// If a tagStats was empty, let's drop it.
// That's a way to avoid empty stats entries or over-time leaks.
if tagStats.isEmpty() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch, indeed, should look cleaner with this.

@LotharSee LotharSee merged commit ac089b2 into master Oct 20, 2017
@dtilghman dtilghman deleted the benjamin/misc-improvements branch October 21, 2017 05:14
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants