'fluentbit - exclude specific kubernetes annotation from exported log metadata

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?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source