新增:rpc 无服务注册处理

git-svn-id: svn://47.119.165.148/zhub@130 e63fbceb-bcc3-4977-ac22-735b83d8d0f4
This commit is contained in:
lxy
2021-10-18 08:02:59 +00:00
parent df84efffce
commit a254269684
2 changed files with 36 additions and 0 deletions

View File

@@ -510,6 +510,20 @@ func (s *ZSub) Clearup() {
}
}
func (s *ZSub) noSubscribe(topic string) bool {
zTopic := s.topics[topic]
if zTopic == nil || len(zTopic.groups) == 0 {
return true
}
for _, g := range zTopic.groups {
if len(g.conns) > 0 {
return false
}
}
return true
}
func ZSubx() *ZSub {
return zsub
}