Skip to content

Commit

Permalink
Fixed fluentd non-json parsing bug by multi_format plugin.
Browse files Browse the repository at this point in the history
  • Loading branch information
shanewxy committed Dec 24, 2019
1 parent 0256255 commit eae4caa
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions pkg/controllers/user/logging/generator/templatefilter.go
Expand Up @@ -125,13 +125,19 @@ var FilterTemplate = `
{{define "filter-json"}}
{{- if .EnableJSONParsing}}
<filter {{ .ContainerLogSourceTag}}.**>
<filter cluster.**>
@type parser
key_name log
reserve_data true
<parse>
@type json
@type multi_format
<pattern>
format json
</pattern>
<pattern>
format none
</pattern>
</parse>
key_name log
reserve_data true
</filter>
{{end}}
{{end}}
Expand Down

0 comments on commit eae4caa

Please sign in to comment.