kafka

package
v1.40.0 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KafkaLogger

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

func NewKafkaLogger

func NewKafkaLogger(l logger.Logger, opts ...Opt) *KafkaLogger

func (*KafkaLogger) Level

func (l *KafkaLogger) Level() kgo.LogLevel

Level is for the kgo.Logger interface.

func (*KafkaLogger) Log

func (l *KafkaLogger) Log(level kgo.LogLevel, msg string, keyvals ...interface{})

type Opt

type Opt interface {
	// contains filtered or unexported methods
}

Opt applies options to the kafka logger.

func WithLevel

func WithLevel(level logger.Level) Opt

WithLevel sets a static level for the kgo.Logger Level function.

func WithLevelFn

func WithLevelFn(fn func() kgo.LogLevel) Opt

WithLevelFn sets a function that can dynamically change the log level.

Jump to

Keyboard shortcuts

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