-
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 modules dev guide #3616
Conversation
3d474d2
to
d0ef8e4
Compare
Basic guide on creating new filebeat modules.
d0ef8e4
to
4e24cbc
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.
I left some minor comments. I really like the tutorial style documentation.
All Filebeat modules currently live in the main | ||
https://github.com/elastic/beats[Beats] repository. To clone the repository and | ||
build Filebeat (which you will need for testing), please follow the general | ||
Beats https://github.com/elastic/beats/blob/master/CONTRIBUTING.md[CONTRIBUTING] |
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.
Not only related to this guide, but we should probably have contributing as part of the docs to also have it specific to a version.
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.
Yeah, we should probably move that to the docs.
There's quite a lot going on in the above, so let's break it down: | ||
|
||
* The name of the variable is `paths` and the default value is | ||
`["/example/test.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.
It could be confusing that here the compact array form is used, but above it the example not. For people familiar with Yaml, it is obvious.
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.
I rephrased it to avoid having to use the compact form.
[source,yaml] | ||
---- | ||
ingest_pipeline: ingest/pipeline.json | ||
prospectors: config/testfileset.yml |
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.
Just realising it now that this should probably be singular prospector
as now only one prospector can be defined.
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.
Good catch, that's wrong here in the docs.
pattern: "^# User@Host: " | ||
negate: true | ||
match: after | ||
input_type: 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.
input_type: log exists twice
[source,shell] | ||
---- | ||
$ cd filebeat/module/{module}/ | ||
python ../dev-tools/export_dashboards.py --regex {module} --dir _meta/kibana |
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.
I think the path to the dev-tools needs a few more ../
Basic guide on creating new filebeat modules. (cherry picked from commit 5c8215f)
Basic guide on creating new filebeat modules. (cherry picked from commit 5c8215f)
Basic guide for creating a new module.
Part of #3159.