Add check for zero-length server addresses

This commit is contained in:
Chris S. Kim 2022-08-24 13:30:52 -04:00
parent 1e7a3b8d8d
commit 6f98c853b8
1 changed files with 4 additions and 1 deletions

View File

@ -833,7 +833,10 @@ func (m *subscriptionManager) subscribeServerAddrs(
serverAddrs = append(serverAddrs, grpcAddr) serverAddrs = append(serverAddrs, grpcAddr)
} }
// TODO(peering): handle empty addresses here? if len(serverAddrs) == 0 {
m.logger.Warn("did not find any server addresses with external gRPC ports to publish")
continue
}
updateCh <- cache.UpdateEvent{ updateCh <- cache.UpdateEvent{
CorrelationID: subServerAddrs, CorrelationID: subServerAddrs,