-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
x-pack/metricbeat/module/statsd: Skip invalid statsd packet(s) #35075
x-pack/metricbeat/module/statsd: Skip invalid statsd packet(s) #35075
Conversation
This pull request doesn't have a |
This pull request does not have a backport label.
To fixup this pull request, you need to add the backport labels for the needed
|
While making the changes I'll also found a bug in the statsd's event parser where the parser can't parse all valid values. I'll open an issue. Fix is pretty simple for the same. It's an important one so I'd try to do it ASAP. |
b758041
to
3203dc4
Compare
This pull request is now in conflicts. Could you fix it? 🙏
|
3f47fce
to
e46c0b1
Compare
…parsing Previously, invalid statsd metric packets would break the ingestion and further metric packets were left unparsed. Now it'd be able to skip invalid packets and continue the parsing.
015969c
to
55802a6
Compare
55802a6
to
04f5645
Compare
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!
This pull request is now in conflicts. Could you fix it? 🙏
|
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!
What does this PR do?
Previously, invalid statsd metric packets would break the ingestion and further metric packets were left unparsed. Now it'd be able to skip invalid packets and continue the parsing. Also made some nitpick fixes (removal of unused vars, usage of proper methods, migrate away from github.com/pkg/errors etc.). Also, made some preallocation changes which are kind of micro-perf improvement and also made did code reorganization to make the code better; although the latter could be done in a different pull request.
Why is it important?
Previously, during parsing of events sent by a statsd client, one invalid packet could stop the entire parsing then and there even if there are valid packets that are waiting to be parsed.
Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.How to test this PR locally
Run go tests in the concerned package:
Related issues