Skip to content

Commit

Permalink
Docfix (#280)
Browse files Browse the repository at this point in the history
* fix parser example
* fix deprected parser configs
  • Loading branch information
pepov authored and ahma committed Dec 6, 2019
1 parent 3ce772a commit 12ea5bd
Show file tree
Hide file tree
Showing 12 changed files with 27 additions and 27 deletions.
4 changes: 2 additions & 2 deletions charts/logging-demo/templates/flow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ spec:
- parser:
remove_key_name_field: true
reserve_data: true
parsers:
- type: nginx
parse:
type: nginx
selectors:
app.kubernetes.io/name: log-generator
app.kubernetes.io/instance: {{ .Release.Name }}
Expand Down
6 changes: 3 additions & 3 deletions docs/crds.md
Original file line number Diff line number Diff line change
Expand Up @@ -375,10 +375,10 @@ metadata:
namespace: default
spec:
filters:
- parse:
- parser:
remove_key_name_field: true
parsers:
- type: nginx
parse:
type: nginx
- tag_normaliser:
format: ${namespace_name}.${pod_name}.${container_name}
outputRefs:
Expand Down
4 changes: 2 additions & 2 deletions docs/example-es-nginx.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,8 @@ spec:
- parser:
remove_key_name_field: true
reserve_data: true
parsers:
- type: nginx
parse:
type: nginx
selectors:
app: nginx
outputRefs:
Expand Down
4 changes: 2 additions & 2 deletions docs/example-kafka-nginx.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,8 @@ spec:
- parser:
remove_key_name_field: true
reserve_data: true
parsers:
- type: nginx
parse:
type: nginx
selectors:
app: nginx
outputRefs:
Expand Down
4 changes: 2 additions & 2 deletions docs/examples/logging_flow_geoip.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ spec:
format: ${namespace_name}.${pod_name}.${container_name}
- parser:
remove_key_name_field: true
parsers:
- type: nginx
parse:
type: nginx
- geoip:
records:
- city: ${city.names.en["remote"]}
Expand Down
4 changes: 2 additions & 2 deletions docs/examples/logging_flow_with_dedot.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ spec:
filters:
- parser:
remove_key_name_field: true
parsers:
- type: nginx
parse:
type: nginx
- tag_normaliser:
format: ${namespace_name}.${pod_name}.${container_name}
- dedot: {}
Expand Down
4 changes: 2 additions & 2 deletions docs/examples/logging_flow_with_filters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ spec:
filters:
- parser:
remove_key_name_field: true
parsers:
- type: nginx
parse:
type: nginx
- tag_normaliser:
format: ${namespace_name}.${pod_name}.${container_name}
outputRefs:
Expand Down
4 changes: 2 additions & 2 deletions docs/examples/logging_flow_with_multi_format.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ metadata:
spec:
filters:
- parser:
parsers:
- type: multi_format
parse:
type: multi_format
patterns:
- format: nginx
- format: regexp
Expand Down
4 changes: 2 additions & 2 deletions docs/logging-operator-monitoring.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,8 +218,8 @@ spec:
- parser:
remove_key_name_field: true
reserve_data: true
parsers:
- type: nginx
parse:
type: nginx
selectors:
app.kubernetes.io/instance: nginx-demo
app.kubernetes.io/name: nginx-logging-demo
Expand Down
4 changes: 2 additions & 2 deletions docs/plugins/filters/geoip.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
format: ${namespace_name}.${pod_name}.${container_name}
- parser:
remove_key_name_field: true
parsers:
- type: nginx
parse:
type: nginx
- geoip:
geoip_lookup_keys: remote_addr
records:
Expand Down
4 changes: 2 additions & 2 deletions pkg/sdk/model/filter/geoip.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ import (
// format: ${namespace_name}.${pod_name}.${container_name}
// - parser:
// remove_key_name_field: true
// parsers:
// - type: nginx
// parse:
// type: nginx
// - geoip:
// geoip_lookup_keys: remote_addr
// records:
Expand Down
8 changes: 4 additions & 4 deletions pkg/sdk/model/filter/parser_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ func TestParser(t *testing.T) {
CONFIG := []byte(`
remove_key_name_field: true
reserve_data: true
parsers:
- type: nginx
parse:
type: nginx
`)
expected := `
<filter **>
Expand All @@ -51,8 +51,8 @@ func TestParserMultiParser(t *testing.T) {
CONFIG := []byte(`
remove_key_name_field: true
reserve_data: true
parsers:
- type: multi_format
parse:
type: multi_format
patterns:
- format: nginx
- format: regexp
Expand Down

0 comments on commit 12ea5bd

Please sign in to comment.