testing

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2021 License: MIT Imports: 14 Imported by: 0

Documentation

Overview

Package testing provides functions to aid in testing kafmesh services.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Emitter

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

Emitter is used to emit messages into kafka for testing

func NewEmitter

func NewEmitter(brokers []string, registry *runner.Registry) *Emitter

NewEmitter creates a new test emitter

func (*Emitter) Emit

func (e *Emitter) Emit(key string, message runner.Message) error

Emit a message to kafka using the topic extracted from the name

func (*Emitter) EmitToTopic

func (e *Emitter) EmitToTopic(topic string, key string, message runner.Message) error

EmitToTopic emits a message to kafka

Jump to

Keyboard shortcuts

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