Conversation
Signed-off-by: Hiroshi Hatake <hiroshi@chronosphere.io>
d2cb767 to
7a60df0
Compare
7a60df0 to
0bd350d
Compare
…alid status Signed-off-by: Hiroshi Hatake <hiroshi@chronosphere.io>
0bd350d to
fbaedef
Compare
Contributor
Author
|
I resync implementation on this PR what winevt_c's PR does. I tested to try to make invalid status but the event signal does not respond for stale of EvtSubscribe. Checking WAIT_FAILED brunch is just for needed for the possibility to be returned from WaitForSingleObject Windows API. |
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.
Fluent Bit is also using pull subscription model for collecting Windows EventLog. Through a registered signal, we're able to obtain the internal state of EvtSubscribe API.
Like as fluent-plugins-nursery/winevt_c#44 fix, Fluent Bit can be made to detect the failure of the subscription.
We need to check it for more strict approach to handle subscription for EventLog.
When failed status is returned from a registered signal, we should recreate the subscription if possible.
This signal approach is inspired from the article: https://learn.microsoft.com/en-us/windows/win32/wes/subscribing-to-events#pull-subscriptions
This article describes that when using the pull type of subscription, EvtSubscribe can tell whether Windows EventLogs are collected or not via a registered signal.
Enter
[N/A]in the box, if an item is not applicable to your change.Testing
Before we can approve your change; please submit the following in a comment:
If this is a change to packaging of containers or native binaries then please confirm it works for all targets.
ok-package-testlabel to test for all targets (requires maintainer to do).Documentation
Backporting
Fluent Bit is licensed under Apache 2.0, by submitting this pull request I understand that this code will be released under the terms of that license.