Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Host string `json:"host" yaml:"host"` //rabbitmq地址
UserName string `json:"userName" yaml:"userName"` //用户名
Password string `json:"password" yaml:"password"` //密码
Port int `json:"port" yaml:"port"` //端口号
Vhost string `json:"vhost" yaml:"vhost"` //rabbitmq虚拟主机
QueueName string `json:"queueName" yaml:"queueName"` //队列名
Exchange string `json:"exchange" yaml:"exchange"` //交换机
ExchangeType string `json:"exchangeType" yaml:"exchangeType"` //交换机类型
RoutingKey string `json:"routingKey" yaml:"routingKey"` //路由键
Tag string `json:"tag" yaml:"tag"` //标签
}
Config rabbit配置结构体
type Consumer ¶
type Consumer struct {
// contains filtered or unexported fields
}
Consumer 消费者结构体
func GetConsumer ¶
func (*Consumer) AnnounceQueue ¶
AnnounceQueue 根据路由键重新绑定队列
type Producer ¶
type Producer struct {
// contains filtered or unexported fields
}
Producer 生产者结构体
func GetProducer ¶
Click to show internal directories.
Click to hide internal directories.