mrabbitmq

package
v1.31.0-beta.10 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RabbitMQConnection

type RabbitMQConnection struct {
	ConnectionStringSource string
	Queue                  string
	Exchange               string
	Key                    string
	Host                   string
	Port                   string
	User                   string
	Pass                   string
	Channel                *amqp.Channel
	Logger                 mlog.Logger
	Connected              bool
}

RabbitMQConnection is a hub which deal with rabbitmq connections.

func (*RabbitMQConnection) Connect

func (rc *RabbitMQConnection) Connect() error

Connect keeps a singleton connection with rabbitmq.

func (*RabbitMQConnection) GetNewConnect

func (rc *RabbitMQConnection) GetNewConnect() (*amqp.Channel, error)

GetNewConnect returns a pointer to the rabbitmq connection, initializing it if necessary.

Jump to

Keyboard shortcuts

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