-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
in_tail: Ensure to discard TailWatcher with missing target when follo…
…w_inodes For example, when a rotation process is slow, there is a small time lag between moving and adding files. There is a possibility that StatWatcher notifies too quickly to the TailWatcher before the new file is moved to that target path. From the TailWatcher, it appears as if the file is resurrected once it disappeared. In this case, `refresh_watcher` can't recognize it, so TailWatcher needs to discard self correctly. In the previous implementation, it was not done. So it caused the handle leak and log duplication. (Please check the added test-case) Signed-off-by: Daijiro Fukuda <[email protected]>
- Loading branch information
Showing
2 changed files
with
143 additions
and
4 deletions.
There are no files selected for viewing
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
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