Completely ignore files older then 'ignore_older' setting#324
Open
Gleb-Gadyatskiy wants to merge 1 commit intologstash-plugins:mainfrom
Open
Completely ignore files older then 'ignore_older' setting#324Gleb-Gadyatskiy wants to merge 1 commit intologstash-plugins:mainfrom
Gleb-Gadyatskiy wants to merge 1 commit intologstash-plugins:mainfrom
Conversation
Gleb-Gadyatskiy
commented
Feb 23, 2024
| private | ||
|
|
||
| def can_exclude?(watched_file, new_discovery) | ||
| if watched_file.file_ignorable? |
Author
There was a problem hiding this comment.
If file should be ignored - we should not include it in list of watched files at all
Gleb-Gadyatskiy
commented
Feb 23, 2024
| logger.trace(__method__.to_s) | ||
| watched_files.each do |watched_file| | ||
| next unless watched_file.rotation_in_progress? | ||
| next unless !watched_file.ignored? && watched_file.rotation_in_progress? |
Author
There was a problem hiding this comment.
Ignored files should not be monitored at all
Gleb-Gadyatskiy
commented
Feb 23, 2024
Author
Gleb-Gadyatskiy
left a comment
There was a problem hiding this comment.
Please review proposed fix for Elastic Support Case #01555020
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.
RE: Elastic support case #01555020
Completely ignore files older then 'ignore_older' setting because we have hundreds of thousands of files in the same folder (logs from a 3d party app) but need to monitor/ingest only recent