Skip to content

Commit 82a27be

Browse files
committed
filelog update
1 parent 43f834f commit 82a27be

File tree

2 files changed

+10
-17
lines changed

2 files changed

+10
-17
lines changed

content/en/ninja-workshops/10-advanced-otel/3-filelog/3-1-filelog-configuration.md

Lines changed: 9 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -8,26 +8,19 @@ Check that you are in the `[WORKSHOP]/3-filelog` directory. Open the `agent.yam
88

99
{{% notice title="Exercise" style="green" icon="running" %}}
1010

11-
- **Add the `filelog` receiver**: The Filelog receiver reads log data from a file and includes custom resource attributes in the log data:
11+
- **Add the `filelog` receiver**: The [**FileLog Receiver**](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/receiver/filelogreceiver/README.md) reads log data from a file and includes custom resource attributes in the log data:
1212

1313
```yaml
14-
# Define a filelog receiver named "quotes"
15-
filelog/quotes:
16-
# Specifies the file to read log data from (quotes.log)
17-
include: ./quotes.log
18-
# Includes the full file path in the log data
19-
include_file_path: true
20-
# Excludes the file name from the log data
21-
include_file_name: false
22-
# Add custom resource attributes to the log data
23-
resource:
24-
# Sets the source of the log data to "quotes.log"
25-
com.splunk.source: ./quotes.log
26-
# Sets the sourcetype for the log data to "quotes"
27-
com.splunk.sourcetype: quotes
14+
filelog/quotes: # Receiver Type/Name
15+
include: ./quotes.log # The file to read log data from (quotes.log)
16+
include_file_path: true # Includes the full file path in the log data
17+
include_file_name: false # Excludes the file name from the log data
18+
resource: # Add custom resource attributes to the log data
19+
com.splunk.source: ./quotes.log # Sets the source of the log data to "quotes.log"
20+
com.splunk.sourcetype: quotes # Sets the sourcetype for the log data to "quotes"
2821
```
2922
30-
- Add `filelog/quotes` receiver to the `receivers` array in the `logs` section of the pipelines. (make sure it also contains `otlp`)
23+
- **Add `filelog/quotes` receiver** to the `receivers` array in the `logs` section of the pipelines. (make sure it also contains `otlp`)
3124

3225
{{% /notice %}}
3326

content/en/ninja-workshops/10-advanced-otel/3-filelog/_index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title: 3. Filelog Receiver Configuration
2+
title: 3. Setting up our Log file
33
linkTitle: 3. Filelog Setup
44
time: 10 minutes
55
weight: 3

0 commit comments

Comments
 (0)