-
Notifications
You must be signed in to change notification settings - Fork 2.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
help request: syslog plugin / attribute 'name' confusion #10474
Comments
APISIX loggers send logs in batches. The name here is the ID of the batch processor for the plugin, which conveniently inherits the plugin's name. However I noticed the value is hardcoded in, which means what you configure actually doesn't matter. I opened a PR to removed the If I'm not wrong on this, we should remove name attribute from the doc for all loggers that hard code the value in. For sys log specifically, the value is hard coded here: apisix/apisix/plugins/syslog/init.lua Line 26 in e1503dc
You won't see this value in the actual logs. |
Oh okk, I didn't see that the name in the documentation was similar as in this line and thus meant it would correspond to the batch processing part (even if ignored) 👍 Thanks for your help / time, have a nice day ! |
Description
Hi
I'm kind of new to Apisix but I wanted to use the syslog plugin and I had trouble to understand the meaning of the plugin key 'name'.
My original need was to modify what would correspond to the 'tag' part (apisix[pid]) in the syslog message and I thought it would correspond to the plugin attribute 'name'.
But this attribute seems to be ignored as I couldn't find it in my remote logs. (other plugin attributes would get applied correctly so it seems not to be a config problem on my side)
I tried to see it via a tcpdump what's been received and I couldn't retrieves the value anywhere, I also tried to grep 'name' in the LUA syslog plugin files and I couldn't see a reference to this.
So I wanted to know what is the usage / impact of this attribute regarding the syslog plugin ?
Thanks for your help, best regards.
Environment
apisix version
): 3.6.0uname -a
):Linux 5.10.0-25-amd64 change: added doc of how to load plugin. #1 SMP Debian 5.10.191-1 (2023-08-16) x86_64 GNU/Linuxopenresty -V
ornginx -V
): nginx/1.18.0curl http://127.0.0.1:9090/v1/server_info
):luarocks --version
):The text was updated successfully, but these errors were encountered: