kafka

package
v0.0.0-...-0a06464 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewKafka

func NewKafka(logger logger.Logger) pubsub.PubSub

NewKafka returns a new kafka pubsub instance.

Types

type PubSub

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

func (*PubSub) BulkPublish

BatchPublish messages to Kafka cluster.

func (*PubSub) BulkSubscribe

func (p *PubSub) BulkSubscribe(ctx context.Context, req pubsub.SubscribeRequest,
	handler pubsub.BulkHandler,
) error

func (*PubSub) Close

func (p *PubSub) Close() (err error)

func (*PubSub) Features

func (p *PubSub) Features() []pubsub.Feature

func (*PubSub) GetComponentMetadata

func (p *PubSub) GetComponentMetadata() map[string]string

GetComponentMetadata returns the metadata of the component.

func (*PubSub) Init

func (p *PubSub) Init(ctx context.Context, metadata pubsub.Metadata) error

func (*PubSub) Publish

func (p *PubSub) Publish(ctx context.Context, req *pubsub.PublishRequest) error

Publish message to Kafka cluster.

func (*PubSub) Subscribe

func (p *PubSub) Subscribe(ctx context.Context, req pubsub.SubscribeRequest, handler pubsub.Handler) error

Jump to

Keyboard shortcuts

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