-
Notifications
You must be signed in to change notification settings - Fork 25
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
RHCLOUD-36895 | refactor: reduce logging noise #241
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -94,8 +94,16 @@ func NewConsumerEventLoop( | |
case kafka.Error: | ||
endpoints.IncConsumeErrors() | ||
l.Log.Errorf("Consumer error: %v (%v)\n", e.Code(), e) | ||
case kafka.OffsetsCommitted: | ||
if e.Error != nil { | ||
l.Log.Errorf("Unable to commit offset: %#v", e) | ||
break | ||
} | ||
|
||
l.Log.Debugf("Ignored OffsetsComitted: %#v", e) | ||
|
||
default: | ||
l.Log.Infof("Ignored %v\n", e) | ||
l.Log.Infof("Ignored %#v\n", e) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you add a bit more context to this log message? Maybe something like "Ignored kafka event"? I was a bit stumped the first time I saw the original log message. It took me a minute to figure out what I was seeing getting logged. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, that's a good idea too! Done! |
||
} | ||
|
||
} | ||
|
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.
What do you think about making this a trace level log?
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.
Yes, even better. Done!