-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
proxy: added multithreaded worker support for proxy plugins #3863
Conversation
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.
Could you fix warning ?
I confirmed below delay plugin. diff --git a/examples/out_gstdout/out_gstdout.go b/examples/out_gstdout/out_gstdout.go
index 8a0acd9..9c99a74 100644
--- a/examples/out_gstdout/out_gstdout.go
+++ b/examples/out_gstdout/out_gstdout.go
@@ -31,6 +31,8 @@ func FLBPluginFlush(data unsafe.Pointer, length C.int, tag *C.char) int {
var ts interface{}
var record map[interface{}]interface{}
+ time.Sleep(time.Second * 60)
+
// Create Fluent Bit decoder
dec := output.NewDecoder(data, int(length)) a.conf
b.conf:
Native out_stdout flushes without preventing by go plugin.
|
There are 3 golang plugin threads. 👍
|
@gautampunhani Thank you. Could you modify commit message ? In this case, you updated flb_output.c. Warning is removed.👍 |
@gautampunhani Please modify commit message.
|
This patch adds worker support to golang output plugins, without which if golang plugins were becoming unresponsive it was blocking other i/p and o/p plugins as well This fixes issue fluent/fluent-bit-go#45 Signed-off-by: Gautam Punhani <[email protected]>
… declaration Signed-off-by: Gautam Punhani <[email protected]>
network: added a time delta to the UDP timeout to keep it from ticking after the upstream timeout handler. Signed-off-by: Leonardo Alminana <[email protected]>
Signed-off-by: Eduardo Silva <[email protected]>
Calls to flb_malloc() normally log allocation failures with flb_errno(). This commit adds the same logging for allocation failures in the Onigmo library. This should help disambiguate errors in flb_regex_do() that are due to memory issues as opposed to actual regular expression match failures. Signed-off-by: Aaron Jacobs <[email protected]>
Signed-off-by: Eduardo Silva <[email protected]>
It detects fluent#3727 Signed-off-by: Takahiro Yamashita <[email protected]>
Signed-off-by: Takahiro Yamashita <[email protected]>
Signed-off-by: Stephen Lee <[email protected]>
When upload_id is not set in create_multipart_upload() (which can occur in some failure modes), subsequent retries will segfault when checking this ID in complete_multipart_upload(). This commit simply checks that the upload ID has been set and returns the usual error code instead of crashing if not. It also logs an error message for the user. Discussed in fluent#3838. Signed-off-by: Aaron Jacobs <[email protected]>
Closing this PR, have created a new one : #3908 |
This applies the same code change brought in for making output plugins performant in v1.7.0 to the proxy plugins of Go.
Without this change if the go output plugin gets slow/unresponsive, other input plugins and output plugins also were getting stuck because of single-threaded nature of invocation.
This addresses issue fluent-bit-go#45
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:
Please note that, Valgrind with golang plugins show leaks without this change as well
Documentation
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.