[skip e2e]Add log for indexcoord peek indexnode (#13855)

Signed-off-by: Cai.Zhang <cai.zhang@zilliz.com>
pull/13881/head
cai.zhang 2021-12-21 16:08:59 +08:00 committed by GitHub
parent 72b4e1f718
commit f4ac7cbfd1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 1 deletions

View File

@ -116,9 +116,13 @@ func (nm *NodeManager) PeekClient(meta Meta) (UniqueID, types.IndexNode) {
return UniqueID(-1), nil
}
nodeID := nm.pq.Peek(dataSize*indexSizeFactor, meta.indexMeta.Req.IndexParams, meta.indexMeta.Req.TypeParams)
if nodeID == -1 {
log.Error("No IndexNode available", zap.Uint64("data size", dataSize),
zap.Uint64("IndexNode must have memory size", dataSize*indexSizeFactor))
}
client, ok := nm.nodeClients[nodeID]
if !ok {
log.Error("IndexCoord NodeManager PeekClient", zap.Any("There is no IndexNode client corresponding to NodeID", nodeID))
log.Error("IndexCoord NodeManager PeekClient", zap.Int64("There is no IndexNode client corresponding to NodeID", nodeID))
return nodeID, nil
}
log.Debug("IndexCoord NodeManager PeekClient ", zap.Int64("node", nodeID), zap.Uint64("data size", dataSize))