kafka

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type File

type File struct {
	Id     string
	Buffer []byte
	Sent   uint64
}

type KafkaProducer

type KafkaProducer interface {
	Produce(msg *kafka.Message, deliveryChan chan kafka.Event) error
	Close()
}

type Plugin

type Plugin struct {
	Producer    KafkaProducer
	Topic       string
	MessageSize int
	CloseChan   chan bool
	FileSize    uint64
	CurrentFile *File
}

func NewPlugin

func NewPlugin(config *config.KafkaPluginConfig) (*Plugin, error)

func (*Plugin) Start

func (p *Plugin) Start(ctx context.Context) chan<- string

Start produces Kafka messages containing data that is written to the returned channel

Jump to

Keyboard shortcuts

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