consumer

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConsumerInput

type ConsumerInput struct {
	// KafkaBrokers is a string of addresses of Kafka broker systems
	KafkaBrokers      []string
	KafkaVersion      sarama.KafkaVersion
	KafkaTopic        string
	KafkaProtoSchema  proto.Message
	KafkaLogErrors    bool
	MsgDelimitWithLen bool
}

type KafkaConsumer

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

func NewKafkaConsumer

func NewKafkaConsumer(input ConsumerInput) *KafkaConsumer

func (*KafkaConsumer) DecodeAndPrintMsg

func (kc *KafkaConsumer) DecodeAndPrintMsg(msg *sarama.ConsumerMessage) error

func (*KafkaConsumer) GetMsgChan

func (kc *KafkaConsumer) GetMsgChan() chan *sarama.ConsumerMessage

func (*KafkaConsumer) InitSaramaConsumer

func (kc *KafkaConsumer) InitSaramaConsumer() error

func (*KafkaConsumer) Stop

func (kc *KafkaConsumer) Stop()

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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