mq

package
v1.28.0 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2023 License: LGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

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

type Consumer

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

func NewConsumer

func NewConsumer(opts ...Option) (*Consumer, error)

func (*Consumer) Start

func (c *Consumer) Start() error

func (*Consumer) Stop

func (c *Consumer) Stop() error

type MessageHandler

type MessageHandler interface {
	HandleMessage([]byte)
}

type Option

type Option func(*Config)

func WithExchange

func WithExchange(exchange string) Option

func WithExchangeType added in v1.0.1

func WithExchangeType(exchangeType string) Option

func WithHandler

func WithHandler(h MessageHandler) Option

func WithLogger

func WithLogger(logger *logrus.Entry) Option

func WithQueueName

func WithQueueName(queueName string) Option

func WithRoutingKey added in v1.0.1

func WithRoutingKey(routingKey string) Option

func WithURI

func WithURI(uri string) Option

Jump to

Keyboard shortcuts

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