Pulsar
Publish observability events to Apache Pulsar topics
Configuration
Example configurations
{
"sinks": {
"my_sink_id": {
"type": "pulsar",
"inputs": [
"my-source-or-transform-id"
],
"endpoint": "pulsar://127.0.0.1:6650",
"encoding": {
"codec": "json"
},
"healthcheck": null,
"topic": "topic-1234"
}
}
}
[sinks.my_sink_id]
type = "pulsar"
inputs = [ "my-source-or-transform-id" ]
endpoint = "pulsar://127.0.0.1:6650"
topic = "topic-1234"
[sinks.my_sink_id.encoding]
codec = "json"
---
sinks:
my_sink_id:
type: pulsar
inputs:
- my-source-or-transform-id
endpoint: pulsar://127.0.0.1:6650
encoding:
codec: json
healthcheck: null
topic: topic-1234
{
"sinks": {
"my_sink_id": {
"type": "pulsar",
"inputs": [
"my-source-or-transform-id"
],
"auth": null,
"endpoint": "pulsar://127.0.0.1:6650",
"buffer": null,
"encoding": {
"codec": "json"
},
"healthcheck": null,
"topic": "topic-1234"
}
}
}
[sinks.my_sink_id]
type = "pulsar"
inputs = [ "my-source-or-transform-id" ]
endpoint = "pulsar://127.0.0.1:6650"
topic = "topic-1234"
[sinks.my_sink_id.encoding]
codec = "json"
---
sinks:
my_sink_id:
type: pulsar
inputs:
- my-source-or-transform-id
auth: null
endpoint: pulsar://127.0.0.1:6650
buffer: null
encoding:
codec: json
healthcheck: null
topic: topic-1234
auth
optional objectauth.token
optional string literalbuffer
optional objectbuffer.max_events
common optional uinttype = "memory"
500
(events)buffer.max_size
required uintThe maximum size of the buffer on the disk. Must be at least 128 megabytes (134217728 bytes).
Note that during normal disk buffer operation, the disk buffer can create one additional 128 megabyte block so the minimum disk space required is actually 256 megabytes.
type = "disk"
buffer.type
common optional string literal enumOption | Description |
---|---|
disk | Stores the sink’s buffer on disk. This is less performant, but durable. Data will not be lost between restarts. Will also hold data in memory to enhance performance. WARNING: This may stall the sink if disk performance isn’t on par with the throughput. For comparison, AWS gp2 volumes are usually too slow for common cases. |
memory | Stores the sink’s buffer in memory. This is more performant, but less durable. Data will be lost if Vector is restarted forcefully. |
memory
buffer.when_full
optional string literal enumOption | Description |
---|---|
block | Applies back pressure when the buffer is full. This prevents data loss, but will cause data to pile up on the edge. |
drop_newest | Drops new data as it’s received. This data is lost. This should be used when performance is the highest priority. |
block
encoding
required objectConfigures the encoding specific sink behavior.
Note: When data in encoding
is malformed, currently only a very generic error “data did not match any variant of untagged enum EncodingConfig” is reported. Follow this issue to track progress on improving these error messages.
encoding.codec
required string literal enumOption | Description |
---|---|
json | JSON encoded event. |
text | The message field from the event. |
encoding.except_fields
optional [string]encoding.only_fields
optional [string]encoding.timestamp_format
optional string literal enumOption | Description |
---|---|
rfc3339 | Formats as a RFC3339 string |
unix | Formats as a unix timestamp |
rfc3339
endpoint
required string literalhealthcheck
common optional objecthealthcheck.enabled
common optional booltrue
inputs
required [string]A list of upstream source or transform
IDs. Wildcards (*
) are supported.
See configuration for more info.
Telemetry
Metrics
linkbuffer_byte_size
gaugecomponent_id
instead. The value is the same as component_id
.buffer_discarded_events_total
countercomponent_id
instead. The value is the same as component_id
.buffer_events
gaugecomponent_id
instead. The value is the same as component_id
.buffer_received_event_bytes_total
countercomponent_id
instead. The value is the same as component_id
.buffer_received_events_total
countercomponent_id
instead. The value is the same as component_id
.buffer_sent_event_bytes_total
countercomponent_id
instead. The value is the same as component_id
.buffer_sent_events_total
countercomponent_id
instead. The value is the same as component_id
.component_received_event_bytes_total
countercomponent_id
instead. The value is the same as component_id
.component_received_events_count
histogramcomponent_id
instead. The value is the same as component_id
.component_received_events_total
countercomponent_id
instead. The value is the same as component_id
.encode_errors_total
counterevents_in_total
countercomponent_received_events_total
instead.component_id
instead. The value is the same as component_id
.utilization
gaugecomponent_id
instead. The value is the same as component_id
.How it works
Health checks
Require health checks
If you’d like to exit immediately upon a health check failure, you can pass the
--require-healthy
flag:
vector --config /etc/vector/vector.toml --require-healthy
Disable health checks
healthcheck
option to
false
.