Fluentd is not filtering as intended before writing to Elasticsearch

后端 未结 1 1604
悲哀的现实
悲哀的现实 2021-01-28 22:41

Using:

  • Elasticsearch 7.5.1.
  • Fluentd 1.11.2
  • Fluent-plugin-elasticsearch 4.1.3
  • Springboot 2.3.3

I have a Springboot artifact

相关标签:
1条回答
  • 2021-01-28 23:12

    Thanks to @Azeem, and according to grep and regexp features documentation, I got it :).

    I just added this to my Fluentd config file:

    <filter onpay.**>
      @type grep
      <regexp>
        key message
        pattern /^.*inout.*$/
      </regexp>
    </filter>
    

    Any line that does not contain the word "inout" is now excluded.

    0 讨论(0)
提交回复
热议问题