kafkasub

package
v0.0.0-...-6bf298d Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Reader *kafka.Reader
	// contains filtered or unexported fields
}

Client ...

func New

func New(broker, topic, groupID string, logger *zap.Logger, ch chan models.MsgTask) (*Client, error)

New ...

func (*Client) Get

func (c *Client) Get(ctx context.Context, msg *models.MsgTask) error

Get calls (ports.Analyter).WriteEvent method that processes incoming message

func (*Client) Start

func (c *Client) Start(ctx context.Context) error

Start sequentaly reads messages from kafka, commits messages after processing

func (*Client) Stop

func (c *Client) Stop() error

Stop ...

Jump to

Keyboard shortcuts

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