|
@@ -63,8 +63,6 @@ func (c *Connection) Submit(msg Message) {
|
|
|
|
|
|
// Publish will publish a message , and return a chan to wait for completion.
|
|
|
func (c *Connection) Publish(msg Message, timeout time.Duration) error {
|
|
|
-
|
|
|
-
|
|
|
message := msg.(*Publish)
|
|
|
message.MessageID = c.MessageID
|
|
|
c.MessageID++
|
|
@@ -95,6 +93,7 @@ func (c *Connection) Publish(msg Message, timeout time.Duration) error {
|
|
|
}
|
|
|
|
|
|
func (c *Connection) confirmPublish(MessageID uint16) {
|
|
|
+ server.Log.Debugf("[confirmPublish]收到消息Id: %d", MessageID)
|
|
|
waitCh, exist := c.MessageWaitChan[MessageID]
|
|
|
if exist {
|
|
|
waitCh <- nil
|