Skip to content
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

writer: log a message when a trace is dropped #942

Merged
merged 2 commits into from
May 20, 2019

Conversation

jd
Copy link
Contributor

@jd jd commented May 17, 2019

There's no way to know that the queue is getting full and that some traces are
dropped. At least write a log message so the user knows something's wrong.

@jd jd requested a review from a team as a code owner May 17, 2019 13:10
@@ -159,6 +159,7 @@ def put(self, item):
if qsize != 0:
idx = random.randrange(0, qsize)
self.queue[idx] = item
log.warn("Writer queue is full has more than %d traces, some traces will be lost", self.maxsize)
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
log.warn("Writer queue is full has more than %d traces, some traces will be lost", self.maxsize)
log.warn('Writer queue is full has more than %d traces, some traces will be lost', self.maxsize)

brettlangdon
brettlangdon previously approved these changes May 17, 2019
@brettlangdon brettlangdon modified the milestones: 0.25.0, 0.26.0 May 17, 2019
There's no way to know that the queue is getting full and that some traces are
dropped. At least write a log message so the user knows something's wrong.
@jd
Copy link
Contributor Author

jd commented May 17, 2019

I think I'll never manage to get this quote thing right 😅

@brettlangdon
Copy link
Member

Ha, some day we'll move to black or something and it won't matter anymore

@jd jd merged commit 5f001e0 into DataDog:master May 20, 2019
@jd jd deleted the log-on-drop-writer-q branch May 20, 2019 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants