rabbitmq

package
v0.0.0-...-ce453ac Latest Latest
Warning

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

Go to latest
Published: May 25, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DoWithTries

func DoWithTries(fn func() error, attempts int, delay time.Duration) (err error)

Types

type RabbitMQConnection

type RabbitMQConnection struct {
	Connection  *amqp.Connection
	ChannelPool chan *amqp.Channel
}

func NewRabbitMQConnection

func NewRabbitMQConnection(uri string, poolSize int) (*RabbitMQConnection, error)

func (*RabbitMQConnection) Close

func (rmq *RabbitMQConnection) Close()

func (*RabbitMQConnection) Consume

func (rmq *RabbitMQConnection) Consume(queue string) (<-chan amqp.Delivery, func(), error)

func (*RabbitMQConnection) GetChannel

func (rmq *RabbitMQConnection) GetChannel() (*amqp.Channel, error)

func (*RabbitMQConnection) InitQueues

func (rmq *RabbitMQConnection) InitQueues(queues []string) error

func (*RabbitMQConnection) Publish

func (rmq *RabbitMQConnection) Publish(queue string, message []byte) error

func (*RabbitMQConnection) ReleaseChannel

func (rmq *RabbitMQConnection) ReleaseChannel(ch *amqp.Channel)

Jump to

Keyboard shortcuts

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