Cherry-pick #25036 to 7.x: Initialize support for ignore_inactive in filestream input#25140
Merged
kvch merged 1 commit intoelastic:7.xfrom Apr 19, 2021
Merged
Cherry-pick #25036 to 7.x: Initialize support for ignore_inactive in filestream input#25140kvch merged 1 commit intoelastic:7.xfrom
kvch merged 1 commit intoelastic:7.xfrom
Conversation
This PR adds support for a more flexible file ignoring in `filestream` input. A new setting is introduced named `ignore_inactive`. At the moment it only supports two values: `since_last_start` and `since_first_start`. If `since_last_start` is selected, the input ignores every file that has not been updated since Filebeat has been started. If `since_first_start` is chosen files that haven't been written since Filebeat has been started the first time on a given host are ignored. (cherry picked from commit 3f39dd8)
Contributor
|
Pinging @elastic/agent (Team:Agent) |
Contributor
💔 Build Failed
Expand to view the summary
Build stats
Test stats 🧪
Trends 🧪Steps errors
Expand to view the steps failures
|
| Test | Results |
|---|---|
| Failed | 0 |
| Passed | 46713 |
| Skipped | 5176 |
| Total | 51889 |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Cherry-pick of PR #25036 to 7.x branch. Original message:
What does this PR do?
This PR adds support for a more flexible file ignoring in
filestreaminput. A new setting is introduced namedignore_inactive. At the moment it only supports two values:since_last_startandsince_first_start.If
since_last_startis selected, the input ignores every file that has not been updated since Filebeat has been started. Ifsince_first_startis chosen files that haven't been written since Filebeat has been started the first time on a given host are ignored.I am submitting tests in a follow-up PR.
Why is it important?
It extends the existing
ingore_oldersupport offilestream.Open question
Should we save the size of the files to the registry, so if they get updated the input can start with the new lines?
Checklist
- [ ] I have made corresponding changes to the documentation- [ ] I have added tests that prove my fix is effective or that my feature works- [ ] I have added an entry inCHANGELOG.next.asciidocorCHANGELOG-developer.next.asciidoc.