Closed blaggacao closed 4 years ago
Fun fact, it seems only keys with a .
in it fail as I don't see other labels
/ annotations
keys failing such as "k8s-app": "fluent-bit-logging"
EDIT: or is it the /
?
Yaey! I can almost confirm, cause this filter eliminates the errors and all seems to work.
[FILTER]
Name nest
Match *
Operation lift
Nested_under kubernetes
[FILTER]
Name modify
Match *
Remove labels
Remove annotations
I tested:
[FILTER]
Name nest
Match *
Operation lift
Nested_under kubernetes
[FILTER]
Name modify
Match *
Rename labels _k8s_labels
Rename annotations _k8s_annotations
Doesn't work either and explains the error some people report in the comments there.
Never seen this (no idea of c), but I could imagine there is an oversight in the valid chars, here... : https://github.com/fluent/fluent-bit/blob/dbd8de76c49fadd46d50f57f5a5783934b99feeb/src/flb_pack.c#L779-L792
Just checked, it't the U+002F / 2f SOLIDUS
which is valid in k8s but missing here.
@manuelluis , can you take a look at this issue ?
The gelf format defines the key as ^[\w.-]*$ : which is chars in the set [A-Za-z0-9_.-], '/' is not a valid char for a key in gelf.
The same problem in: https://github.com/fluent/fluent-bit/pull/1166
A generic solution could be replace in the gelf ouput, every char in a key that not match [A-Za-z0-9.-] with an underscore char: '' .
If this is solution is ok, I can make a pull request with the changes.
A generic solution could be replace in the gelf ouput, every char in a key that not match [A-Za-z0-9.-] with an underscore char: '' .
True! Looks like a good idea.
@manuelluis yes please!
@manuelluis You can start from #1166 if you want, I only replaced /
there, which worked fine for me so far.
Really looking forward for this one... thanks!
This should be fixed in #1166 .
@blaggacao , can you confirm?
What is the fix for this ? I am using fluent-bit with Azure kubernetics 1.16.1 Getting this error
What is the fix for this ? I am using fluent-bit with Azure kubernetics 1.16.1 Getting this error
Me too, i'm using fluent-bit 1.3.7 installed with helm (repo stable/fluent-bit, docker image fluent/fluent-bit:1.3.7) but the error persist. I hope can you help me.
@lbogdan
This should be fixed in #1166 .
I'm sorry, I have abandoned this road.
I'm closing. I'd suggest affected parties to file a new issue, which they can maintain.
This issue persists with v3.0.0.
Bug Report
Version 1.0.6
Gelf output barks on (valid) nested objects from the kubernetes filter.
Already filtered by:
resulting in a sample log message:
barking in
flb_msgpack_gelf_key
, possibly due to a loop error inflb_msgpack_gelf_flatten