Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AutoReconnectProducer ¶
type AutoReconnectProducer struct { Connected bool Queue *amqp.Queue // amqp queue Channel *amqp.Channel //amqp channel // contains filtered or unexported fields }
AutoReconnectProducer Rec This producer can auto reconnect MQ
func CreateNew ¶
func CreateNew(config *config.AmqpConfig) (*AutoReconnectProducer, error)
CreateNew new instance for AutoReconnectProducer.
func (*AutoReconnectProducer) Close ¶
func (s *AutoReconnectProducer) Close()
Close close connection
func (*AutoReconnectProducer) PublishMessage ¶
func (s *AutoReconnectProducer) PublishMessage(exchange string, contentType string, bytes []byte) error
PublishMessage spd
func (*AutoReconnectProducer) SendProtobuf ¶
func (s *AutoReconnectProducer) SendProtobuf(exchange string, bytes []byte) error
SendProtobuf spd
Click to show internal directories.
Click to hide internal directories.