kafkagen

package
v0.0.0-...-96f1409 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2022 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type JSONEvent

type JSONEvent fake.Event

JSONEvent implements the sarama.Encoder interface for Event using json.

func (JSONEvent) Encode

func (e JSONEvent) Encode() ([]byte, error)

Encode marshals the event to json.

func (JSONEvent) Length

func (e JSONEvent) Length() int

Length returns the length of the marshalled json.

type Main

type Main struct {
	Hosts        []string
	Topic        string
	Group        string
	RestProxyURL string

	Rate time.Duration
}

Main holds the execution state for the kafka generator.

func NewMain

func NewMain() *Main

NewMain returns a new Main.

func (*Main) Run

func (m *Main) Run() error

Run runs the kafka generator.

Jump to

Keyboard shortcuts

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