Documentation
¶
Index ¶
- func Publish(exchange string, sessions chan chan AmqpSession, messages <-chan AmqpMessage)
- func Redial(ctx context.Context, exchange string, url string) chan chan AmqpSession
- func Subscribe(exchange string, sessions chan chan AmqpSession, messages chan<- AmqpMessage)
- type AmqpMessage
- type AmqpSession
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Publish ¶
func Publish(exchange string, sessions chan chan AmqpSession, messages <-chan AmqpMessage)
Publish deals with setting up a process to handle publishing messages to an exchange.
func Redial ¶
func Redial(ctx context.Context, exchange string, url string) chan chan AmqpSession
Redial continuously connects to the message broker exiting when it can no longer make the connection.
func Subscribe ¶
func Subscribe(exchange string, sessions chan chan AmqpSession, messages chan<- AmqpMessage)
Subscribe deals with setting up a new listener to events published to a certain exchange.
Types ¶
type AmqpMessage ¶
AmqpMessage with headers and content type to work as an intermediary for application specific data structures.
type AmqpSession ¶
type AmqpSession struct { *amqp.Connection *amqp.Channel }
AmqpSession provides a composition of a connection and channel to be used in the self-reconnecting AMQP client.
func (AmqpSession) Close ¶
func (s AmqpSession) Close() error
Close deals with closing the connection of the provided session.
Click to show internal directories.
Click to hide internal directories.