-
Notifications
You must be signed in to change notification settings - Fork 431
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
Generate full Beats field definitions, including nested fields #379
Conversation
This also fixes a bug where the `group` fieldset was not actually being nested in all places where user is nested (e.g. `source.user.group.*`).
c16c812
to
f146f11
Compare
@ruflin Could you check this out? A big difference between this file and the previous one we crafted manually (other than the YAML rendering of strings) is that fields no longer are in the original order. If that's good with you for this, I think this is ready for final review. |
7c6a7c3
to
6f6efb7
Compare
Fields listed under each |
If it's not being used then I'd drop 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. I looked over the generated fields.ecs.yml. This is nice. I didn't spend much time on the Python.
It's a Rubyist's Python, so probably better like that 😆 |
@ruflin Will ping you on the backport for review on Monday. Happy to adjust anything needed. But I'm moving forward here to prepare the 1.0 backport of this, then make elastic/beats#11150 final, so it can hopefully be merged Monday. |
…ncluding nested fields (elastic#379) Backport of PR elastic#379 to 1.0 branch. Original message: This work has revealed a subtle bug in the generated files schema.csv and both ES templates, which were missing the group fieldset in all places where user is reused. (e.g. `host.user.group.*`) Upon comparing this new file to the fields definition file we had handcrafted for Beats (prior to this), it also revealed we had missed a few things in the Beats field definitions: - We had forgotten to define the reusable `user` fieldset `client`, `destination`, `server` and `source`. They previously had been missed. - We had forgotten to define the reusable `geo` fieldset at `host.geo.*` and `observer.geo.*`
…g nested fields (#379) (#381) Backport of PR #379 to 1.0 branch. Original message: This work has revealed a subtle bug in the generated files schema.csv and both ES templates, which were missing the group fieldset in all places where user is reused. (e.g. `host.user.group.*`) Upon comparing this new file to the fields definition file we had handcrafted for Beats (prior to this), it also revealed we had missed a few things in the Beats field definitions: - We had forgotten to define the reusable `user` fieldset in `client`, `destination`, `server` and `source`. They previously had been missed. - We had forgotten to define the reusable `geo` fieldset at `host.geo.*` and `observer.geo.*`
This work has revealed a subtle bug in the generated files schema.csv and both ES templates, which were missing the
group
fieldset in all places whereuser
is reused. (e.g.host.user.group.*
)Notes
reusable
). This new generator will filter them, to let through only what matters. Question: should we let through the ECSlevel
?