adapter

package
v0.0.0-...-8a2214f Latest Latest
Warning

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

Go to latest
Published: Feb 14, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TransformMessage

func TransformMessage(msg *sarama.ConsumerMessage) *kafka.Message

Types

type ConsumerGroupHandler

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

func NewConsumerGroupHandler

func NewConsumerGroupHandler(handler kafka.Handler, opts ...ConsumerGroupHandlerOption) (*ConsumerGroupHandler, error)

func (*ConsumerGroupHandler) Cleanup

func (*ConsumerGroupHandler) ConsumeClaim

func (*ConsumerGroupHandler) Setup

type ConsumerGroupHandlerOption

type ConsumerGroupHandlerOption func(*ConsumerGroupHandler)

func ConsumerGroupHandlerErrorHandler

func ConsumerGroupHandlerErrorHandler(errHandler transport.ErrorHandler) ConsumerGroupHandlerOption

type Listener

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

func NewListener

func NewListener(
	topics []string,
	consumerGroup sarama.ConsumerGroup,
	consumerGroupHandler sarama.ConsumerGroupHandler,
	opts ...ListenerOption,
) (*Listener, error)

func (*Listener) Listen

func (l *Listener) Listen(ctx context.Context) error

type ListenerOption

type ListenerOption func(*Listener)

func ListenerErrorHandler

func ListenerErrorHandler(errHandler transport.ErrorHandler) ListenerOption

Jump to

Keyboard shortcuts

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