Change "dropped events" warning to debug-level log message#11
Merged
stevvooe merged 1 commit intodocker:masterfrom Jun 1, 2016
Merged
Change "dropped events" warning to debug-level log message#11stevvooe merged 1 commit intodocker:masterfrom
stevvooe merged 1 commit intodocker:masterfrom
Conversation
Contributor
I'd like to address this issue. The goal of go-events is to be able to reliably produce and consume events without losing them. A dropped event can be really problematic in practice. I suspect the current consumer shutdown procedure is at fault here. This close should be propagated at queue ingress, rather than just drop in flight messages on close. |
In a project where I use go-events, quite a few unit tests and benchmarks read from a queue until they find what they're looking for, and then stop reading. There may be more events published to the queue afterwards, but there's no non-racy way to consume all of them and still have the test terminate. Thus, these tests and benchmarks tend to log many `WARN[0004] eventqueue: dropped event` messages. Change this to the debug log level, so applications and unit tests which use go-events are not forced to always consume all events to suppress these messages. Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2e85840 to
cc270ab
Compare
Collaborator
Author
|
Added a big TODO. |
Contributor
|
LGTM |
aaronlehmann
pushed a commit
to aaronlehmann/docker
that referenced
this pull request
Jul 18, 2016
This is needed to suppress a log message about a harmless condition which was previously logged at the WARNING log level with potentially high frequency (docker/go-events#11). Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
tiborvass
pushed a commit
to tiborvass/docker
that referenced
this pull request
Jul 26, 2016
This is needed to suppress a log message about a harmless condition which was previously logged at the WARNING log level with potentially high frequency (docker/go-events#11). Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com> (cherry picked from commit db9bc51) Signed-off-by: Tibor Vass <tibor@docker.com>
rchicoli
pushed a commit
to rchicoli/docker
that referenced
this pull request
Nov 12, 2016
This is needed to suppress a log message about a harmless condition which was previously logged at the WARNING log level with potentially high frequency (docker/go-events#11). Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com> (cherry picked from commit db9bc51) Signed-off-by: Tibor Vass <tibor@docker.com>
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.
In a project where I use go-events, quite a few unit tests and
benchmarks read from a queue until they find what they're looking for,
and then stop reading. There may be more events published to the queue
afterwards, but there's no non-racy way to consume all of them and still
have the test terminate. Thus, these tests and benchmarks tend to log
many
WARN[0004] eventqueue: dropped eventmessages.Change this to the debug log level, so applications and unit tests which
use go-events are not forced to always consume all events to suppress
these messages.