Handle error returned by GetClusterInfos() (#30919)

A recent change to the enterprise cluster code introduced a change to the enterprise API interface. GetClusterInfos() can now return an error. This commit introduces code to handle that error.
Этот коммит содержится в:
David Krauser
2025-05-12 13:37:58 -04:00
коммит произвёл GitHub
родитель dfe6478fd7
Коммит 4b64eb0e39
10 изменённых файлов: 48 добавлений и 28 удалений

Просмотреть файл

@@ -20,8 +20,8 @@ type MockApp struct {
clusterInfo []*model.ClusterInfo
}
func (ma MockApp) GetClusterStatus(rctx request.CTX) []*model.ClusterInfo {
return ma.clusterInfo
func (ma MockApp) GetClusterStatus(rctx request.CTX) ([]*model.ClusterInfo, error) {
return ma.clusterInfo, nil
}
func (ma *MockApp) SetInSync() {