Skip to content

Commit e766cdc

Browse files
authored
Merge pull request #1679 from fluent/lynettemiles/sc-136146/update-fluent-bit-docs-pipeline-filters-expect
2 parents 0252ec7 + 108994b commit e766cdc

File tree

1 file changed

+11
-22
lines changed

1 file changed

+11
-22
lines changed

pipeline/filters/expect.md

Lines changed: 11 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,23 @@
11
---
2-
description: >-
3-
Made for testing: make sure that your records contain the expected key and
4-
values
2+
description: Testing records to ensure they contain an expected key and values
53
---
64

75
# Expect
86

9-
The _expect_ filter plugin allows you to validate that records match certain criteria in their structure, like validating that a key exists or it has a specific value.
7+
The _expect_ filter plugin lets you validate that records match certain criteria in their structure, like validating that a key exists or it has a specific value.
108

11-
The following page just describes the configuration properties available, for a detailed explanation of its usage and use cases, please refer the following page:
9+
For a detailed explanation of its usage and use cases, see [Validating and your Data and Structure](../../local-testing/validating-your-data-and-structure.md).
1210

13-
* [Validating and your Data and Structure](../../local-testing/validating-your-data-and-structure.md)
14-
15-
## Configuration Parameters
11+
## Configuration parameters
1612

1713
The plugin supports the following configuration parameters:
1814

1915
| Property | Description |
2016
| :--- | :--- |
21-
| key\_exists | Check if a key with a given name exists in the record. |
22-
| key\_not\_exists | Check if a key does not exist in the record. |
23-
| key\_val\_is\_null | check that the value of the key is NULL. |
24-
| key\_val\_is\_not\_null | check that the value of the key is NOT NULL. |
25-
| key\_val\_eq | check that the value of the key equals the given value in the configuration. |
26-
| action | action to take when a rule does not match. The available options are `warn` , `exit` or "result_key". On `warn`, a warning message is sent to the logging layer when a mismatch of the rules above is found; using `exit` makes Fluent Bit abort with status code `255`; `result_key` is to add a matching result to each record. |
27-
| result\_key | specify a key name of matching result. This key is to be used only when 'action' is 'result_key'.|
28-
29-
## Getting Started
30-
31-
As mentioned on top, refer to the following page for specific details of usage of this filter:
32-
33-
* [Validating and your Data and Structure](../../local-testing/validating-your-data-and-structure.md)
34-
17+
| `key_exists` | Check if a key with a given name exists in the record. |
18+
| `key_not_exists` | Check if a key doesn't exist in the record. |
19+
| `key_val_is_null` | Check that the value of the key is `NULL`. |
20+
| `key_val_is_not_null` | Check that the value of the key is `NOT NULL`. |
21+
| `key_val_eq` | Check that the value of the key equals the given value in the configuration. |
22+
| `action` | Action to take when a rule doesn't match. Available options are `warn` , `exit` or `result_key`. On `warn`, a warning message is sent to the logging layer when a mismatch of the `key*` rules is found. Using `exit` makes Fluent Bit exit with status code `255`. `result_key` adds a matching result to each record. |
23+
| `result_key` | Specify a key name for the matching result added when `action` is set to `result_key`. |

0 commit comments

Comments
 (0)