kafka

package
v1.7.3 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetDomainEventInfra added in v1.3.7

func GetDomainEventInfra() freedom.DomainEventInfra

func SettingConfig

func SettingConfig(confFunc func(config *sarama.Config, other map[string]interface{}))

SettingConfig .

func Sleep

func Sleep(retry int, minBackoff time.Duration, maxBackoff time.Duration)

Types

type Consumer

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

Consumer .

func (*Consumer) Booting

func (c *Consumer) Booting(sb freedom.SingleBoot)

Booting .

func (*Consumer) Close

func (c *Consumer) Close()

func (*Consumer) Listen added in v1.5.2

func (c *Consumer) Listen()

func (*Consumer) StartUp added in v1.6.2

func (c *Consumer) StartUp(f func())

StartUp .

type Limiter

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

func (*Limiter) Close

func (s *Limiter) Close(deltas ...int32)

func (*Limiter) Open

func (s *Limiter) Open(deltas ...int32)

type Msg

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

Msg .

func (*Msg) Publish added in v1.3.5

func (msg *Msg) Publish()

Publish .

func (*Msg) SelectClient added in v1.3.5

func (msg *Msg) SelectClient(producer string) *Msg

SelectClient .

func (*Msg) SetHeaders

func (msg *Msg) SetHeaders(headers map[string]string) *Msg

SetHeaders .

func (*Msg) SetWorker added in v1.7.1

func (msg *Msg) SetWorker(worker freedom.Worker) *Msg

SetWorker .

type Producer

type Producer interface {
	NewMsg(topic string, content []byte, producerName ...string) *Msg
}

type ProducerImpl added in v1.4.3

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

ProducerImpl .

func (*ProducerImpl) Booting added in v1.4.3

func (p *ProducerImpl) Booting(sb freedom.SingleBoot)

Booting .

func (*ProducerImpl) DomainEvent added in v1.4.3

func (p *ProducerImpl) DomainEvent(producer, topic string, data []byte, worker freedom.Worker, header ...map[string]string)

DomainEvent .

func (*ProducerImpl) NewMsg added in v1.4.3

func (p *ProducerImpl) NewMsg(topic string, content []byte, producerName ...string) *Msg

NewMsg .

func (*ProducerImpl) StartUp added in v1.6.2

func (c *ProducerImpl) StartUp(f func())

StartUp .

Jump to

Keyboard shortcuts

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