kafka

package
v1.2.3 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2021 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewKafka

func NewKafka(l logger.Logger) pubsub.PubSub

NewKafka returns a new kafka pubsub instance

Types

type Kafka

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

Kafka allows reading/writing to a Kafka consumer group

func (*Kafka) Close

func (k *Kafka) Close() error

func (*Kafka) Features

func (k *Kafka) Features() []pubsub.Feature

func (*Kafka) Init

func (k *Kafka) Init(metadata pubsub.Metadata) error

Init does metadata parsing and connection establishment

func (*Kafka) Publish

func (k *Kafka) Publish(req *pubsub.PublishRequest) error

Publish message to Kafka cluster

func (*Kafka) Subscribe

func (k *Kafka) Subscribe(req pubsub.SubscribeRequest, handler pubsub.Handler) error

Subscribe to topic in the Kafka cluster This call cannot block like its sibling in bindings/kafka because of where this is invoked in runtime.go

Jump to

Keyboard shortcuts

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