producer

package module
v0.0.0-...-6f9e92a Latest Latest
Warning

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

Go to latest
Published: Jan 21, 2022 License: BSD-3-Clause Imports: 14 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

New create a new kafka activity

Types

type Activity

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

Activity is a kafka activity

func (*Activity) Eval

func (act *Activity) Eval(ctx activity.Context) (done bool, err error)

Eval implements the evaluation of the kafka activity

func (*Activity) Metadata

func (*Activity) Metadata() *activity.Metadata

Metadata returns the metadata for the kafka activity

type Input

type Input struct {
	Message interface{} `md:"message,required"` // The message to send
}

func (*Input) FromMap

func (i *Input) FromMap(values map[string]interface{}) error

func (*Input) ToMap

func (i *Input) ToMap() map[string]interface{}

type KafkaConnection

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

func (*KafkaConnection) Connection

func (c *KafkaConnection) Connection() sarama.SyncProducer

func (*KafkaConnection) Stop

func (c *KafkaConnection) Stop() error

type Output

type Output struct {
	Partition int32 `md:"partition"` // Documents the partition that the message was placed on
	OffSet    int64 `md:"offset"`    // Documents the offset for the message
}

func (*Output) FromMap

func (o *Output) FromMap(values map[string]interface{}) error

func (*Output) ToMap

func (o *Output) ToMap() map[string]interface{}

type Settings

type Settings struct {
	BrokerUrls   string `md:"brokerUrls,required"` // The Kafka cluster to connect to
	User         string `md:"user"`                // If connecting to a SASL enabled port, the user id to use for authentication
	Password     string `md:"password"`            // If connecting to a SASL enabled port, the password to use for authentication
	TrustStore   string `md:"trustStore"`          // If connecting to a TLS secured port, the directory containing the certificates representing the trust chain for the connection. This is usually just the CACert used to sign the server's certificate
	Topic        string `md:"topic,required"`      // The Kafka topic on which to place the message
	PeriodOfTime string `md:"periodOfTime"`        // ("s", "m", "h")
}

Settings setting struct

Jump to

Keyboard shortcuts

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