Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Connection ¶
type Connection struct { Conn *amqp.Connection Channel *amqp.Channel Queue amqp.Queue Err chan error }
Connection is the RabbitMQ connection
func (*Connection) Connect ¶
func (c *Connection) Connect() error
Connect initialize the RabbitMQ connection
func (*Connection) Consume ¶
func (c *Connection) Consume() (map[string]<-chan amqp.Delivery, error)
Consume consumes the messages from the queues and passes it as map of chan of amqp.Delivery
func (*Connection) HandleConsumedMessages ¶ added in v1.0.2
func (c *Connection) HandleConsumedMessages(q string, message <-chan amqp.Delivery, fn func(Connection, string, <-chan amqp.Delivery), second int)
HandleConsumedMessages handles the consumed messages from the queues
func (*Connection) Reconnect ¶
func (c *Connection) Reconnect(second int)
Reconnect reconnects the RabbitMQ connection
Click to show internal directories.
Click to hide internal directories.