mirror of
https://github.com/fhmq/hmq.git
synced 2026-05-04 07:08:32 +00:00
fix fail in cluster deploy (#86)
Co-authored-by: janson <janson@gmail.com>
This commit is contained in:
@@ -107,6 +107,7 @@ func (c *client) init() {
|
||||
c.ctx, c.cancelFunc = context.WithCancel(context.Background())
|
||||
c.subMap = make(map[string]*subscription)
|
||||
c.topicsMgr = c.broker.topicsMgr
|
||||
c.routeSubMap = make(map[string]uint64)
|
||||
}
|
||||
|
||||
func (c *client) readLoop() {
|
||||
@@ -343,6 +344,8 @@ func (c *client) ProcessSubscribe(packet *packets.SubscribePacket) {
|
||||
case CLIENT:
|
||||
c.processClientSubscribe(packet)
|
||||
case ROUTER:
|
||||
fallthrough
|
||||
case REMOTE:
|
||||
c.processRouterSubscribe(packet)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -46,6 +46,8 @@ func (c *client) SendConnect() {
|
||||
return
|
||||
}
|
||||
m := packets.NewControlPacket(packets.Connect).(*packets.ConnectPacket)
|
||||
m.ProtocolName = "MQIsdp"
|
||||
m.ProtocolVersion = 3
|
||||
|
||||
m.CleanSession = true
|
||||
m.ClientIdentifier = c.info.clientID
|
||||
|
||||
Reference in New Issue
Block a user