Reputation: 3438
I have some pods that contain an annotation with a very long value. I feel this is causing issues when fluentbit attempts to export the logs to elasticsearch. I don't need this particular annotation to be exported with the log metadata. I've tried to prevent this annotation from being exported by turning off annotations in the fluentbit kubernetses filter like so:
[FILTER]
Name kubernetes
Match kube.*
Merge_Log On
Keep_Log Off
K8S-Logging.Parser On
K8S-Logging.Exclude On
Annotations Off
However, this causes us other issues, as we need to some of the other annotations the filter is removing. So my question is, is there a way to exclude a single/specific annotation from the metadata, rather than exclude all the annotations?
Upvotes: 0
Views: 2317
Reputation: 860
Use these filters:
[FILTER] Name nest Match application.* Operation lift Nested_under kubernetes Add_prefix Kube. [FILTER] Name modify Match application.* Remove Kube.annotation.<Metadata_1> Remove Kube.annotation.<Metadata_2> Remove Kube.annotation.<Metadata_3> [FILTER] Name nest Match application.* Operation nest Wildcard Kube.* Nested_under kubernetes Remove_prefix Kube.
Upvotes: 0