kafka

package
v0.25.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 20, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package kafka provides an output implementation for streaming data to Apache Kafka topics. It enables sending events or log lines from the stream utility to a specified Kafka cluster, handling connection setup, message production, and topic management. This output supports configurable options such as target topic and broker address.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(opts *output.Options) (output.Output, error)

New returns a new kafka output.

Types

type Output

type Output struct {
	// contains filtered or unexported fields
}

Output is a kafka output.

func (*Output) Close

func (o *Output) Close() error

Close closes the connection to the configured endpoint.

func (*Output) DialContext

func (o *Output) DialContext(_ context.Context) error

DialContext connects to the configured endpoint.

func (*Output) Write

func (o *Output) Write(b []byte) (int, error)

Write writes data to the kafka topic.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL