tmq

package
v3.5.4 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2024 License: MIT Imports: 8 Imported by: 2

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(conf *tmq.ConfigMap) (*Consumer, error)

NewConsumer Create new TMQ consumer with TMQ config

func (*Consumer) Assignment added in v3.5.0

func (c *Consumer) Assignment() (partitions []tmq.TopicPartition, err error)

func (*Consumer) Close

func (c *Consumer) Close() error

Close release consumer

func (*Consumer) Commit

func (c *Consumer) Commit() ([]tmq.TopicPartition, error)

func (*Consumer) CommitOffsets added in v3.5.1

func (c *Consumer) CommitOffsets(offsets []tmq.TopicPartition) ([]tmq.TopicPartition, error)

func (*Consumer) Committed added in v3.5.1

func (c *Consumer) Committed(partitions []tmq.TopicPartition, timeoutMs int) (offsets []tmq.TopicPartition, err error)

func (*Consumer) Poll

func (c *Consumer) Poll(timeoutMs int) tmq.Event

Poll consumer poll message with timeout

func (*Consumer) Position added in v3.5.1

func (c *Consumer) Position(partitions []tmq.TopicPartition) (offsets []tmq.TopicPartition, err error)

func (*Consumer) Seek added in v3.5.0

func (c *Consumer) Seek(partition tmq.TopicPartition, ignoredTimeoutMs int) error

func (*Consumer) Subscribe

func (c *Consumer) Subscribe(topic string, rebalanceCb RebalanceCb) error

func (*Consumer) SubscribeTopics added in v3.1.0

func (c *Consumer) SubscribeTopics(topics []string, rebalanceCb RebalanceCb) error

func (*Consumer) Unsubscribe

func (c *Consumer) Unsubscribe() error

Unsubscribe TMQ unsubscribe

type RebalanceCb added in v3.1.0

type RebalanceCb func(*Consumer, tmq.Event) error

Jump to

Keyboard shortcuts

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