-
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
filebeat/input/udp: convert to v2 input #33930
Conversation
Pinging @elastic/security-external-integrations (Team:Security-External Integrations) |
filebeat/input/udp/input.go
Outdated
|
||
return fmt.Sprintf("%16X", id), nil | ||
} | ||
log.Debugf("udp input '%v' initialized", ctx.ID) |
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.
No need to include the ID in the message since the v2 framework includes the ID in the logger's context.
{"log.level":"debug","@timestamp":"2022-12-06T22:05:07.433-0500","log.logger":"input.udp.udp","log.origin":{"file.name":"udp/input.go","file.line":129},"message":"udp input 'udp-udp.generic-eb7ec6cc-b99b-44b3-a26c-dc2f5bdc2451' initialized","service.name":"filebeat","id":"udp-udp.generic-eb7ec6cc-b99b-44b3-a26c-dc2f5bdc2451","host":"localhost:9514","ecs.version":"1.6.0"}
filebeat/input/udp/input.go
Outdated
return config{ | ||
Config: udp.Config{ | ||
MaxMessageSize: 10 * humanize.KiByte, | ||
// TODO: What should be default port? |
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.
Let's remove the TODOs. I think these have been "decided" given how long they have been the defaults.
Co-authored-by: Andrew Kroh <andrew.kroh@elastic.co>
Kudos, SonarCloud Quality Gate passed! |
Co-authored-by: Andrew Kroh <andrew.kroh@elastic.co>
What does this PR do?
This converts the filebeat UDP input to a v2 input.
Why is it important?
This simplifies the code and improves coherence of the codebase.
Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.Author's Checklist
How to test this PR locally
Related issues
Use cases
Screenshots
Logs