Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions pipeline/processors/conditional-processing.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,11 @@ Conditional processing is available in Fluent Bit version 4.0 and greater.
You can turn a standard processor into a conditional processor by adding a `condition` block to the processor's YAML configuration settings.

{% hint style="info" %}

- Only [YAML configuration files](../../administration/configuring-fluent-bit/yaml/README.md) support processors, including conditional processors.

- Conditional processing isn't supported if you're using a [filter as a processor](../filters).

{% endhint %}

These `condition` blocks use the following syntax:
Expand All @@ -22,7 +25,7 @@ These `condition` blocks use the following syntax:
pipeline:
inputs:
<...>

processors:
logs:
- name: processor_name
Expand Down Expand Up @@ -273,4 +276,4 @@ pipeline:
{% endtab %}
{% endtabs %}

This configuration adds an `alert` field to error logs from critical services, and adds a `paging_required` field to errors that contain specific critical patterns.
This configuration adds an `alert` field to error logs from critical services, and adds a `paging_required` field to errors that contain specific critical patterns.
4 changes: 2 additions & 2 deletions pipeline/processors/content-modifier.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ The actions specify the type of operation to run on top of a specific key or con
| Action | Description |
| ------- | ------------------------------------------------------------ |
| `insert` | Inserts a new key with a value into the target context. The `key` and `value` parameters are required. |
| `upsert` | Given a specific key with a value, the `upsert` operation will try to update the value of the key. If the key does not exist, a new key will be created. The `key` and `value` parameters are required. |
| `upsert` | Given a specific key with a value, the `upsert` operation will try to update the value of the key. If the key doesn't exist, a new key will be created. The `key` and `value` parameters are required. |
| `delete` | Deletes a key from the target context. The `key` parameter is required. |
| `rename` | Changes the name of a key. The `value` set in the configuration will represent the new name. The `key` and `value` parameters are required. |
| `hash` | Replaces the key value with a hash generated by the SHA-256 algorithm, the binary value generated is finally set as a hex string representation. The `key` parameter is required. |
Expand Down Expand Up @@ -281,4 +281,4 @@ pipeline:
```

{% endtab %}
{% endtabs %}
{% endtabs %}
6 changes: 3 additions & 3 deletions pipeline/processors/sampling.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ The latency condition uses the following `conditions` configuration parameters:
| `threshold_ms_low` | Specifies the lower latency threshold. Traces with a duration less than or equal to this value will be sampled. | `0` |
| `threshold_ms_high` | Specifies the upper latency threshold. Traces with a duration greater than or equal to this value will be sampled. | `0` |

The following example waits five seconds before making a decision. It then samples traces based on latency, capturing short traces of 200&nbsp;ms or less and long traces of 3000&nbsp;ms or more. Traces between 200&nbsp;ms and 3000&nbsp;ms are not sampled unless another condition applies.
The following example waits five seconds before making a decision. It then samples traces based on latency, capturing short traces of 200&nbsp;ms or less and long traces of 3000&nbsp;ms or more. Traces between 200&nbsp;ms and 3000&nbsp;ms won't be sampled unless another condition applies.

{% tabs %}
{% tab title="fluent-bit.yaml" %}
Expand Down Expand Up @@ -151,7 +151,7 @@ The span count condition uses the following `conditions` configuration parameter
| `max_spans` | Specifies the minimum number of spans a trace must have to be sampled. | _none_ |
| `min_spans` | Specifies the maximum number of spans a trace can have to be sampled. | _none_ |

The following example configuration waits five seconds before making a decision. It then samples traces with at least three spans but no more than five spans. Traces with less than three spans or greater than five spans are not sampled unless another condition applies.
The following example configuration waits five seconds before making a decision. It then samples traces with at least three spans but no more than five spans. Traces with less than three spans or greater than five spans won't be sampled unless another condition applies.

{% tabs %}
{% tab title="fluent-bit.yaml" %}
Expand Down Expand Up @@ -451,4 +451,4 @@ pipeline:
{% endtab %}
{% endtabs %}

For more details about further processing, read the [content modifier](../processors/content-modifier.md) processor documentation.
For more details about further processing, read the [content modifier](../processors/content-modifier.md) processor documentation.