未验证 提交 d013134b 编写于 作者: X Xiaofan 提交者: GitHub

Enhance error message when coordinator not healthy (#15950)

Signed-off-by: Nxiaofan-luan <xiaofan.luan@zilliz.com>
上级 c2fe12bc
......@@ -81,7 +81,7 @@ func (c *Client) getDataCoordAddr() (string, error) {
ms, ok := msess[key]
if !ok {
log.Debug("DataCoordClient, not existed in msess ", zap.Any("key", key), zap.Any("len of msess", len(msess)))
return "", fmt.Errorf("number of datacoord is incorrect, %d", len(msess))
return "", fmt.Errorf("find no available datacoord, check datacoord state")
}
return ms.Address, nil
}
......
......@@ -98,7 +98,7 @@ func (c *Client) getIndexCoordAddr() (string, error) {
ms, ok := msess[key]
if !ok {
log.Debug("IndexCoordClient msess key not existed", zap.Any("key", key), zap.Any("len of msess", len(msess)))
return "", fmt.Errorf("number of indexcoord is incorrect, %d", len(msess))
return "", fmt.Errorf("find no available indexcoord, check indexcoord state")
}
return ms.Address, nil
}
......
......@@ -81,7 +81,7 @@ func (c *Client) getQueryCoordAddr() (string, error) {
ms, ok := msess[key]
if !ok {
log.Debug("QueryCoordClient msess key not existed", zap.Any("key", key))
return "", fmt.Errorf("number of querycoord is incorrect, %d", len(msess))
return "", fmt.Errorf("find no available querycoord, check querycoord state")
}
return ms.Address, nil
}
......
......@@ -91,7 +91,7 @@ func (c *Client) getRootCoordAddr() (string, error) {
ms, ok := msess[key]
if !ok {
log.Warn("RootCoordClient mess key not exist", zap.Any("key", key))
return "", fmt.Errorf("number of RootCoord is incorrect, %d", len(msess))
return "", fmt.Errorf("find no available rootcoord, check rootcoord state")
}
log.Debug("RootCoordClient GetSessions success", zap.String("address", ms.Address))
return ms.Address, nil
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册