redpanda

package
v1.3.8 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Consumer

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

func NewConsumer

func NewConsumer(kafkaBrokers, httpBrokers, subscribeRegexes []string, groupName, instanceId string, greeter bool) (*Consumer, error)

func (*Consumer) Close

func (c *Consumer) Close() error

Close terminates the Consumer.

func (*Consumer) GetMessage

func (c *Consumer) GetMessage() *shared.KafkaMessage

GetMessage receives a single message.

func (*Consumer) GetMessages

func (c *Consumer) GetMessages() chan *shared.KafkaMessage

GetMessages returns the message channel.

func (*Consumer) GetStats

func (c *Consumer) GetStats() (uint64, uint64)

GetStats returns marked and consumed message counts.

func (*Consumer) GetTopics

func (c *Consumer) GetTopics() []string

func (*Consumer) IsRunning

func (c *Consumer) IsRunning() bool

IsRunning returns the run state.

func (*Consumer) MarkMessage

func (c *Consumer) MarkMessage(msg *shared.KafkaMessage)

MarkMessage marks a message for commit.

func (*Consumer) MarkMessages

func (c *Consumer) MarkMessages(msgs []*shared.KafkaMessage)

MarkMessages marks multiple messages for commit.

func (*Consumer) Start

func (c *Consumer) Start() error

type GroupHandler

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

func (*GroupHandler) Cleanup

func (c *GroupHandler) Cleanup(session sarama.ConsumerGroupSession) error

func (*GroupHandler) ConsumeClaim

func (c *GroupHandler) ConsumeClaim(session sarama.ConsumerGroupSession, claim sarama.ConsumerGroupClaim) error

func (*GroupHandler) Setup

type TopicPartition

type TopicPartition struct {
	Topic     string
	Partition int32
}

Jump to

Keyboard shortcuts

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