kafka_client

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClientKafka

type ClientKafka struct {
	ProducerTopic string
	ConsumerTopic string
	BrokerList    []string
	GroupId       string
	Producer      *healer.Producer
	Consumer      <-chan *healer.FullMessage
	SegConsumer   *kafka.Reader
}

func (*ClientKafka) NewConsumer

func (ka *ClientKafka) NewConsumer(topic string) (<-chan *healer.FullMessage, error)

func (*ClientKafka) NewKafkaConsumer

func (ka *ClientKafka) NewKafkaConsumer(topic string) *kafka.Reader

func (*ClientKafka) NewProducer

func (ka *ClientKafka) NewProducer(topic string) (pro *healer.Producer, err error)

func (*ClientKafka) SendMessage

func (ka *ClientKafka) SendMessage(key string, value string) error

Jump to

Keyboard shortcuts

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