kafka

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2021 License: MPL-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateCodecs

func GenerateCodecs(codecs map[string]string) (map[string]*goavro.Codec, error)

GenerateCodecs - create a map of codec name to the avro codec

func InitKafkaWriter

func InitKafkaWriter(ctx context.Context, topic string) (*kafka.Writer, *kafka.Dialer, error)

InitKafkaWriter - create a kafka writer given a topic

func InstrumentKafka

func InstrumentKafka(ctx context.Context)

InstrumentKafka - setup instrumentation and metrics around our kafka connection

func TLSDialer

func TLSDialer() (*kafka.Dialer, *x509.Certificate, error)

TLSDialer creates a Kafka dialer over TLS. The function requires KAFKA_SSL_CERTIFICATE_LOCATION and KAFKA_SSL_KEY_LOCATION environment variables to be set.

Types

This section is empty.

Jump to

Keyboard shortcuts

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