Documentation
¶
Index ¶
- Variables
- func Close()
- func FatalWorker(timeout time.Duration)
- func Init(uri string) (err error)
- func RestoreConnectionWorker(uri string, queue Queue, timeout time.Duration)
- func RunConsumerForChannelWithCancelAndDbConn(consumer ConsumerWithDbConn, messageChannel MessageChannel, ...)
- type Consumer
- type ConsumerWithDbConn
- type MessageChannel
- type Queue
- func (q Queue) Declare() error
- func (q Queue) GetMessageChannel() MessageChannel
- func (q Queue) Publish(body []byte) error
- func (q Queue) RunConsumer(consumer Consumer)
- func (q Queue) RunConsumerWithCancel(consumer Consumer, ctx context.Context)
- func (q Queue) RunConsumerWithCancelAndDbConn(consumer ConsumerWithDbConn, database *db.Instance, ctx context.Context)
Constants ¶
This section is empty.
Variables ¶
View Source
var (
PrefetchCount int
)
Functions ¶
func FatalWorker ¶
func RestoreConnectionWorker ¶
func RunConsumerForChannelWithCancelAndDbConn ¶
func RunConsumerForChannelWithCancelAndDbConn(consumer ConsumerWithDbConn, messageChannel MessageChannel, database *db.Instance, ctx context.Context)
Types ¶
type MessageChannel ¶
func (MessageChannel) GetMessage ¶
func (mc MessageChannel) GetMessage() amqp.Delivery
type Queue ¶
type Queue string
func (Queue) GetMessageChannel ¶
func (q Queue) GetMessageChannel() MessageChannel
func (Queue) RunConsumer ¶
func (Queue) RunConsumerWithCancel ¶
func (Queue) RunConsumerWithCancelAndDbConn ¶
Click to show internal directories.
Click to hide internal directories.