Documentation ¶
Index ¶
- Variables
- func ConsumeMsg(name string, numOfMessages int32, waitSeconds int64, ...)
- func ConsumeMsg2(name string, numOfMessages int32, waitSeconds int64, ...)
- func ExecuteConsumeMsg(topic string, cli mqHttpSdk.MQConsumer, numOfMessages int32, waitSeconds int64, ...)
- func ExecutePublishMsg(name string, msg MqMsg) (bool, error)
- func GetConsumer(name string) mqHttpSdk.MQConsumer
- func GetProducer(name string) mqHttpSdk.MQProducer
- func Init(cfg *config.RocketmqConfig) bool
- func InitConsumer(config *MqConsumerConfig)
- func InitMq(mqConf *MqConfig)
- func InitProducer(config *MqProducerConfig)
- func PublishMsg(name string, msg MqMsg) (bool, error)
- type MqConfig
- type MqConsumerConfig
- type MqMsg
- type MqProducerConfig
- type MqWorker
Constants ¶
This section is empty.
Variables ¶
View Source
var (
DEBUG = true
)
Functions ¶
func ConsumeMsg ¶
func ConsumeMsg(name string, numOfMessages int32, waitSeconds int64, consumeFunc func(topic string, msg MqMsg) *common.LResult)
ConsumeMsg 消费消息
func ConsumeMsg2 ¶
func ConsumeMsg2(name string, numOfMessages int32, waitSeconds int64, consumeFunc func(topic string, msg MqMsg) *common.LResult)
ConsumeMsg2 消费消息
func ExecuteConsumeMsg ¶
func ExecuteConsumeMsg(topic string, cli mqHttpSdk.MQConsumer, numOfMessages int32, waitSeconds int64, consumeFunc func(topic string, msg MqMsg) *common.LResult)
ExecuteConsumeMsg 执行消费消息
func ExecutePublishMsg ¶
ExecutePublishMsg 执行发送消息
func GetConsumer ¶
func GetConsumer(name string) mqHttpSdk.MQConsumer
func GetProducer ¶
func GetProducer(name string) mqHttpSdk.MQProducer
func Init ¶
func Init(cfg *config.RocketmqConfig) bool
func InitConsumer ¶
func InitConsumer(config *MqConsumerConfig)
func InitProducer ¶
func InitProducer(config *MqProducerConfig)
Types ¶
type MqConsumerConfig ¶
type MqProducerConfig ¶
type MqWorker ¶
type MqWorker struct {
// contains filtered or unexported fields
}
func NewMqWorker ¶
Click to show internal directories.
Click to hide internal directories.