File tree Expand file tree Collapse file tree 1 file changed +10
-10
lines changed
docs/sources/flow/reference/components Expand file tree Collapse file tree 1 file changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -147,27 +147,27 @@ This example consumes Kafka events from the specified brokers and topics
147
147
then forwards them to a ` loki.write ` component using the Kafka timestamp.
148
148
149
149
``` river
150
- loki.relabel "kafka" {
151
- rule {
152
- source_labels = ["__meta_kafka_topic"]
153
- target_label = "topic"
154
- }
155
- }
156
-
157
-
158
150
loki.source.kafka "local" {
159
151
brokers = ["localhost:9092"]
160
152
topics = ["quickstart-events"]
161
153
labels = {component = "loki.source.kafka"}
162
- forward_to = [loki.write.local .receiver]
154
+ forward_to = [loki.relabel.kafka .receiver]
163
155
use_incoming_timestamp = true
164
156
relabel_rules = loki.relabel.kafka.rules
165
157
}
166
158
159
+ loki.relabel "kafka" {
160
+ forward_to = [loki.write.local.receiver]
161
+
162
+ rule {
163
+ source_labels = ["__meta_kafka_topic"]
164
+ target_label = "topic"
165
+ }
166
+ }
167
+
167
168
loki.write "local" {
168
169
endpoint {
169
170
url = "loki:3100/api/v1/push"
170
171
}
171
172
}
172
173
```
173
-
You can’t perform that action at this time.
0 commit comments