-
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
[libbeat] Allow per beat.Client control of event normalization #33657
Merged
andrewkroh
merged 6 commits into
elastic:main
from
andrewkroh:feature/libbeat/event-normalization-override
Nov 14, 2022
Merged
[libbeat] Allow per beat.Client control of event normalization #33657
andrewkroh
merged 6 commits into
elastic:main
from
andrewkroh:feature/libbeat/event-normalization-override
Nov 14, 2022
Conversation
This file contains 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
andrewkroh
added
enhancement
libbeat
backport-skip
Skip notification from the automated backport with mergify
labels
Nov 13, 2022
botelastic
bot
added
the
needs_team
Indicates that the issue/PR needs a Team:* label
label
Nov 13, 2022
Control over the addition of the "generalizeEvent" processor into the publishing pipeline was only available at the Beat level. This adds a new option that can be set by input's when they create their beat.Client. This allows inputs to override the Beat's default behavior. My expected use case it to disable event normalization for inputs that are known to only produce beat.Events containing the standard data types expected by the processors and outputs (i.e. map[string]interface{} containing primitives, slices, or other map[string]interface{}). Inputs would want to disable the event normalization processor if they can because it adds unnecessary processing (recurses over the fields and often allocates).
andrewkroh
force-pushed
the
feature/libbeat/event-normalization-override
branch
from
November 13, 2022 16:02
ccc2fcb
to
118bc11
Compare
Collaborator
andrewkroh
requested review from
belimawr and
faec
and removed request for
a team
November 13, 2022 20:21
andrewkroh
added
Team:Security-External Integrations
Team:Elastic-Agent-Data-Plane
Label for the Agent Data Plane team
labels
Nov 13, 2022
Pinging @elastic/security-external-integrations (Team:Security-External Integrations) |
Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane) |
botelastic
bot
removed
the
needs_team
Indicates that the issue/PR needs a Team:* label
label
Nov 13, 2022
efd6
approved these changes
Nov 13, 2022
6 tasks
andrewkroh
added a commit
to andrewkroh/beats
that referenced
this pull request
Nov 14, 2022
Disable event normalization for the aws-s3 input to reduce allocations when processing events. The input only produces basic types in its events. Either it puts a string into the `message` field or it decodes json into a map[string]interface with encoding/json. Both of those should be fine for the downstream processors and outputs. Relates elastic#33657
andrewkroh
added a commit
that referenced
this pull request
Nov 15, 2022
Disable event normalization for the aws-s3 input to reduce allocations when processing events. The input only produces basic types in its events. Either it puts a string into the `message` field or it decodes json into a map[string]interface with encoding/json. Both of those should be fine for the downstream processors and outputs. Relates #33657
chrisberkhout
pushed a commit
that referenced
this pull request
Jun 1, 2023
Control over the addition of the "generalizeEvent" processor into the publishing pipeline was only available at the Beat level. This adds a new option that can be set by input's when they create their beat.Client. This allows inputs to override the Beat's default behavior. My expected use case it to disable event normalization for inputs that are known to only produce beat.Events containing the standard data types expected by the processors and outputs (i.e. map[string]interface{} containing primitives, slices, or other map[string]interface{}). Inputs would want to disable the event normalization processor if they can because it adds unnecessary processing (recurses over the fields and often allocates). * lint / misspell - fix spelling * lint / unused - remove `drop` field * lint / errorlint - wrap error in fmt.Errorf * lint / errcheck - add missing checks
chrisberkhout
pushed a commit
that referenced
this pull request
Jun 1, 2023
Disable event normalization for the aws-s3 input to reduce allocations when processing events. The input only produces basic types in its events. Either it puts a string into the `message` field or it decodes json into a map[string]interface with encoding/json. Both of those should be fine for the downstream processors and outputs. Relates #33657
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
backport-skip
Skip notification from the automated backport with mergify
enhancement
libbeat
Team:Elastic-Agent-Data-Plane
Label for the Agent Data Plane team
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.
What does this PR do?
Control over the addition of the "generalizeEvent" processor into the publishing pipeline was only available at the Beat level. This adds a new option that can be set by input's when they create their beat.Client.
This allows inputs to override the Beat's default behavior. My expected use case it to disable event normalization for inputs that are known to only produce beat.Events containing the standard data types expected by the processors and outputs (i.e. map[string]interface{} containing primitives, slices, or other map[string]interface{}).
Inputs would want to disable the event normalization processor if they can because it adds unnecessary processing (recurses over the fields and often allocates).
An example usage:
Why is it important?
It allows input authors to make an optimization.
Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.Screenshots