|
1 |
| -# OpenTelemetry Envelope |
| 1 | +# OpenTelemetry envelope |
2 | 2 |
|
3 |
| -The _OpenTelemetry Envelope_ processor is used to transform your data to be compatible with the OpenTelemetry Log schema. If your data was __not__ generated by [OpenTelemetry input](../inputs/opentelemetry.md) and your backend or destination for your logs expects to be in an OpenTelemetry schema. |
| 3 | +The _OpenTelemetry envelope_ processor transforms your data to be compatible with the OpenTelemetry log schema. If your data wasn't generated by the [OpenTelemetry input plugin](../inputs/opentelemetry.md), you can use this processor before sending that data to a destination that expects an OpenTelemetry-compatible schema. |
4 | 4 |
|
5 |
| - |
| 5 | + |
6 | 6 |
|
7 | 7 | {% hint style="info" %}
|
8 | 8 |
|
9 |
| -**Note:** Both processors and this specific component can be enabled only by using |
10 |
| -the YAML configuration format. Classic mode configuration format doesn't support processors. |
| 9 | +Only [YAML configuration files](../administration/configuring-fluent-bit/yaml/README.md) support processors. |
11 | 10 |
|
12 | 11 | {% endhint %}
|
13 | 12 |
|
14 |
| -## Configuration Parameters |
| 13 | +## Configuration parameters |
15 | 14 |
|
16 |
| -The processor does not provide any extra configuration parameter, it can be used directly in your _processors_ Yaml directive. |
| 15 | +The OpenTelemetry envelope processor doesn't use configuration parameters. |
17 | 16 |
|
18 |
| -## Usage Example |
| 17 | +## Examples |
19 | 18 |
|
20 |
| -In this example, we will use the Dummy input plugin to generate a sample message per second, right after is created the processor `opentelemetry_envelope` is used to transform the data to be compatible with the OpenTelemetry Log schema. The output is sent to the standard output and also to an OpenTelemetry collector which is receiving data in port 4318. |
21 |
| - |
22 |
| -Example Fluent Bit and OpenTelemetry collector configuration files: |
| 19 | +The following example uses the `dummy` input plugin to generate one sample message per second, then transforms those messages by using the `opentelemetry_envelope` processor. The resulting transformed data is sent to `stdout` and the `opentelemetry` output plugin. |
23 | 20 |
|
24 | 21 | {% tabs %}
|
25 | 22 | {% tab title="fluent-bit.yaml" %}
|
@@ -77,9 +74,9 @@ service:
|
77 | 74 | {% endtab %}
|
78 | 75 | {% endtabs %}
|
79 | 76 |
|
80 |
| - You will notice in the standard output of Fluent Bit will print the raw representation of the schema, however, the OpenTelemetry collector will receive the data in the OpenTelemetry Log schema. |
| 77 | +The standard output of Fluent Bit prints the raw representation of the schema. However, the OpenTelemetry collector receives the data in an OpenTelemetry-compatible format. |
81 | 78 |
|
82 |
| -Inspecting the output file `out.json` you will see the data in the OpenTelemetry Log schema: |
| 79 | +If you inspect the `out.json` output file, you will see OpenTelemetry-compatible data, similar to the following: |
83 | 80 |
|
84 | 81 |
|
85 | 82 | ```json
|
@@ -107,7 +104,7 @@ Inspecting the output file `out.json` you will see the data in the OpenTelemetry
|
107 | 104 | }
|
108 | 105 | ```
|
109 | 106 |
|
110 |
| -While OpenTelemetry Envelope enrich your logs with the Schema, you might be interested into take a step further and use the [Content Modifier](../processors/content-modifier.md) processor to modify the content of your logs. Here is a quick example that will allow you to add some resource and scope attributes to your logs: |
| 107 | +If you're interested in additional transformations, you can also use the [content modifier](../processors/content-modifier.md) processor to modify the content of your logs. The following example shows how to add resource and scope attributes to logs: |
111 | 108 |
|
112 | 109 | {% tabs %}
|
113 | 110 | {% tab title="fluent-bit.yaml" %}
|
@@ -145,7 +142,7 @@ pipeline:
|
145 | 142 | {% endtab %}
|
146 | 143 | {% endtabs %}
|
147 | 144 |
|
148 |
| -The collector JSON output will look like this: |
| 145 | +The collector JSON output will resemble the following: |
149 | 146 |
|
150 | 147 | ```json
|
151 | 148 | {
|
@@ -181,4 +178,4 @@ The collector JSON output will look like this:
|
181 | 178 | }
|
182 | 179 | ```
|
183 | 180 |
|
184 |
| -For more details about further processing, read the [Content Modifier](../processors/content-modifier.md) processor documentation. |
| 181 | +For more details about further processing, read the [content modifier](../processors/content-modifier.md) processor documentation. |
0 commit comments