kafka

package
v1.0.15 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewConsumerFactory added in v1.0.15

func NewConsumerFactory() component.Factory

func NewProducerFactory added in v1.0.15

func NewProducerFactory() component.Factory

Types

type Consumer

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

func NewConsumer

func NewConsumer(rawConfig string) (*Consumer, error)

func (*Consumer) Instance

func (c *Consumer) Instance() component.Instance

func (*Consumer) Start

func (c *Consumer) Start() error

func (*Consumer) Stop

func (c *Consumer) Stop() error

type ConsumerConfig

type ConsumerConfig struct {
	Name              string   `yaml:"name"`
	Addrs             []string `yaml:"addrs"`
	ConsumerGroup     string   `yaml:"consumer_group"`
	Topics            []string `yaml:"topics"`
	OffsetsInitial    int64    `yaml:"offsets_initial"`
	OffsetsAutoCommit bool     `yaml:"offsets_auto_commit"`
}

func (ConsumerConfig) Marshal added in v1.0.15

func (c ConsumerConfig) Marshal() ([]byte, error)

type Producer

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

func NewProducer

func NewProducer(rawConfig string) (*Producer, error)

func (*Producer) Instance

func (c *Producer) Instance() component.Instance

func (*Producer) Start

func (c *Producer) Start() error

func (*Producer) Stop

func (c *Producer) Stop() error

type ProducerConfig

type ProducerConfig struct {
	Name  string   `yaml:"name"`
	Addrs []string `yaml:"addrs"`
}

func (ProducerConfig) Marshal added in v1.0.15

func (c ProducerConfig) Marshal() ([]byte, error)

Jump to

Keyboard shortcuts

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