rabbitmq

package
v0.0.0-...-983ff77 Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2021 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ExchangeName              = ""
	QueueNameBeginTransaction = "begin_transaction"
	QueueNameEndTransaction   = "end_transaction"
)

Client-specific constants

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client is the RabbitMQ client object

func NewClient

func NewClient(messageBusURI string) *Client

NewClient initializes a new HEP processor

func (*Client) Close

func (c *Client) Close(ctx context.Context) error

Close closes the client to the message bus

func (*Client) Connect

func (c *Client) Connect(ctx context.Context) error

Connect connects the client to the message bus

func (*Client) Publish

func (c *Client) Publish(ctx context.Context, routingKey string, req interface{}) error

Publish publishes a message in the message bus

type ClientInterface

type ClientInterface interface {
	Connect(ctx context.Context) error
	Close(ctx context.Context) error
	Publish(ctx context.Context, routingKey string, req interface{}) error
}

ClientInterface is the interface for RabbitMQ client objects

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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