Documentation ¶
Index ¶
- func NewRabbitMqProducer() *rabbitMqProducer
- type ExchangeOption
- type MqBus
- func (bus *MqBus) PublishDirect(obj interface{}, exchangeOpt ExchangeOption, queueOpt QueueOption, expire int) error
- func (bus *MqBus) PublishFanout(obj interface{}, exchangeOpt ExchangeOption) error
- func (bus MqBus) SubscribeDirect(exchangeOpt ExchangeOption, queueOpt QueueOption, f func([]byte) bool)
- func (bus *MqBus) SubscribeFanout(queueName string, exchangeOpt ExchangeOption, f func([]byte))
- type QueueOption
- type RabbitMqConnPool
- type RabbitMqConsumer
- func (bus RabbitMqConsumer) SubscribeDirect(exchangeOpt ExchangeOption, queueOpt QueueOption, f func([]byte) bool)
- func (bus *RabbitMqConsumer) SubscribeFanout(queueName string, exchangeOpt ExchangeOption, f func([]byte)) error
- func (bus *RabbitMqConsumer) SubscribeFanoutEx(queueName string, exchangeOpt ExchangeOption, f func([]byte))
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRabbitMqProducer ¶
func NewRabbitMqProducer() *rabbitMqProducer
Types ¶
type ExchangeOption ¶
type MqBus ¶
type MqBus struct {
// contains filtered or unexported fields
}
bus
func NewMqEventBus ¶
func NewMqEventBus() *MqBus
func (*MqBus) PublishDirect ¶
func (bus *MqBus) PublishDirect(obj interface{}, exchangeOpt ExchangeOption, queueOpt QueueOption, expire int) error
func (*MqBus) PublishFanout ¶
func (bus *MqBus) PublishFanout(obj interface{}, exchangeOpt ExchangeOption) error
func (MqBus) SubscribeDirect ¶
func (bus MqBus) SubscribeDirect(exchangeOpt ExchangeOption, queueOpt QueueOption, f func([]byte) bool)
func (*MqBus) SubscribeFanout ¶
func (bus *MqBus) SubscribeFanout(queueName string, exchangeOpt ExchangeOption, f func([]byte))
type QueueOption ¶
type RabbitMqConnPool ¶
type RabbitMqConnPool struct {
// contains filtered or unexported fields
}
func NewRabbitMqConnPool ¶
func NewRabbitMqConnPool() *RabbitMqConnPool
func (*RabbitMqConnPool) Free ¶
func (p *RabbitMqConnPool) Free(conn *amqp.Connection) error
func (*RabbitMqConnPool) GetFreeRabbitMqConn ¶
func (p *RabbitMqConnPool) GetFreeRabbitMqConn(timeout time.Duration) (*amqp.Connection, error)
type RabbitMqConsumer ¶
type RabbitMqConsumer struct {
// contains filtered or unexported fields
}
func (RabbitMqConsumer) SubscribeDirect ¶
func (bus RabbitMqConsumer) SubscribeDirect(exchangeOpt ExchangeOption, queueOpt QueueOption, f func([]byte) bool)
func (*RabbitMqConsumer) SubscribeFanout ¶
func (bus *RabbitMqConsumer) SubscribeFanout(queueName string, exchangeOpt ExchangeOption, f func([]byte)) error
func (*RabbitMqConsumer) SubscribeFanoutEx ¶
func (bus *RabbitMqConsumer) SubscribeFanoutEx(queueName string, exchangeOpt ExchangeOption, f func([]byte))
Click to show internal directories.
Click to hide internal directories.