blackhole sink

Streams `log` and `metric` events to a blackhole that simply discards data, designed for testing and benchmarking purposes.

The blackhole sink streams log and metric events to a blackhole that simply discards data, designed for testing and benchmarking purposes.

Config File

vector.toml (example)
vector.toml (schema)
vector.toml (specification)
[sinks.my_sink_id]
type = "blackhole" # must be: "blackhole"
inputs = ["my-source-id"]
print_amount = 1000
healthcheck = true # default

Options

Key

Type

Description

REQUIRED

type

string

The component type required must be: "blackhole"

inputs

[string]

A list of upstream source or transform IDs. See Config Composition for more info. required example: ["my-source-id"]

print_amount

int

The number of events that must be received in order to print a summary of activity. required example: 1000

OPTIONAL

healthcheck

bool

Enables/disables the sink healthcheck upon start. See Health Checks for more info. default: true

How It Works

Delivery Guarantee

Due to the nature of this component, it offers a best effort delivery guarantee.

Environment Variables

Environment variables are supported through all of Vector's configuration. Simply add ${MY_ENV_VAR} in your Vector configuration file and the variable will be replaced before being evaluated.

You can learn more in the Environment Variables section.

Health Checks

Health checks ensure that the downstream service is accessible and ready to accept data. This check is performed upon sink initialization.

If the health check fails an error will be logged and Vector will proceed to start. If you'd like to exit immediately upon health check failure, you can pass the --require-healthy flag:

vector --config /etc/vector/vector.toml --require-healthy

And finally, if you'd like to disable health checks entirely for this sink you can set the healthcheck option to false.

Streaming

The blackhole sink streams data on a real-time event-by-event basis. It does not batch data.

Troubleshooting

The best place to start with troubleshooting is to check the Vector logs. This is typically located at /var/log/vector.log, then proceed to follow the Troubleshooting Guide.

If the Troubleshooting Guide does not resolve your issue, please:

  1. If encountered a bug, please file a bug report.

  2. If encountered a missing feature, please file a feature request.

  3. If you need help, join our chat/forum community. You can post a question and search previous questions.

Resources