mirror of
https://github.com/TeaOSLab/EdgeCommon.git
synced 2025-11-12 03:01:54 +08:00
阶段性提交
This commit is contained in:
@@ -7,11 +7,12 @@ import (
|
||||
|
||||
var SharedNodeClusterDAO = new(NodeClusterDAO)
|
||||
|
||||
// NodeClusterDAO 集群相关操作
|
||||
type NodeClusterDAO struct {
|
||||
BaseDAO
|
||||
}
|
||||
|
||||
// 查找集群
|
||||
// FindEnabledNodeCluster 查找集群
|
||||
func (this *NodeClusterDAO) FindEnabledNodeCluster(ctx context.Context, clusterId int64) (*pb.NodeCluster, error) {
|
||||
clusterResp, err := this.RPC().NodeClusterRPC().FindEnabledNodeCluster(ctx, &pb.FindEnabledNodeClusterRequest{NodeClusterId: clusterId})
|
||||
if err != nil {
|
||||
@@ -19,3 +20,8 @@ func (this *NodeClusterDAO) FindEnabledNodeCluster(ctx context.Context, clusterI
|
||||
}
|
||||
return clusterResp.NodeCluster, nil
|
||||
}
|
||||
|
||||
// FindEnabledNodeClusterConfigInfo 查找集群概要信息
|
||||
func (this *NodeClusterDAO) FindEnabledNodeClusterConfigInfo(ctx context.Context, clusterId int64) (*pb.FindEnabledNodeClusterConfigInfoResponse, error) {
|
||||
return this.RPC().NodeClusterRPC().FindEnabledNodeClusterConfigInfo(ctx, &pb.FindEnabledNodeClusterConfigInfoRequest{NodeClusterId: clusterId})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user