Documentation ¶
Index ¶
- func AddTwoResourceList(oldResourceList corev1.ResourceList, newResourceList corev1.ResourceList) corev1.ResourceList
- func GetPodsByNodeNameForDeletion(nodeName string, nodeDrainHelper *bean.NodeDrainHelper) (*bean.PodDeleteList, []error)
- type K8sCapacityService
- type K8sCapacityServiceImpl
- func (impl *K8sCapacityServiceImpl) CordonOrUnCordonNode(ctx context.Context, request *bean.NodeUpdateRequestDto) (string, error)
- func (impl *K8sCapacityServiceImpl) DeleteNode(ctx context.Context, request *bean.NodeUpdateRequestDto) (*k8s2.ManifestResponse, error)
- func (impl *K8sCapacityServiceImpl) DrainNode(ctx context.Context, request *bean.NodeUpdateRequestDto) (string, error)
- func (impl *K8sCapacityServiceImpl) EditNodeTaints(ctx context.Context, request *bean.NodeUpdateRequestDto) (string, error)
- func (impl *K8sCapacityServiceImpl) GetClusterCapacityDetail(ctx context.Context, cluster *cluster.ClusterBean, callForList bool) (*bean.ClusterCapacityDetail, error)
- func (impl *K8sCapacityServiceImpl) GetClusterCapacityDetailList(ctx context.Context, clusters []*cluster.ClusterBean) ([]*bean.ClusterCapacityDetail, error)
- func (impl *K8sCapacityServiceImpl) GetNode(ctx context.Context, clusterId int, nodeName string) (*corev1.Node, error)
- func (impl *K8sCapacityServiceImpl) GetNodeCapacityDetailByNameAndCluster(ctx context.Context, cluster *cluster.ClusterBean, name string) (*bean.NodeCapacityDetail, error)
- func (impl *K8sCapacityServiceImpl) GetNodeCapacityDetailsListByCluster(ctx context.Context, cluster *cluster.ClusterBean) ([]*bean.NodeCapacityDetail, error)
- func (impl *K8sCapacityServiceImpl) UpdateNodeManifest(ctx context.Context, request *bean.NodeUpdateRequestDto) (*k8s2.ManifestResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddTwoResourceList ¶
func AddTwoResourceList(oldResourceList corev1.ResourceList, newResourceList corev1.ResourceList) corev1.ResourceList
func GetPodsByNodeNameForDeletion ¶
func GetPodsByNodeNameForDeletion(nodeName string, nodeDrainHelper *bean.NodeDrainHelper) (*bean.PodDeleteList, []error)
Types ¶
type K8sCapacityService ¶
type K8sCapacityService interface { GetClusterCapacityDetailList(ctx context.Context, clusters []*cluster.ClusterBean) ([]*bean.ClusterCapacityDetail, error) GetClusterCapacityDetail(ctx context.Context, cluster *cluster.ClusterBean, callForList bool) (*bean.ClusterCapacityDetail, error) GetNodeCapacityDetailsListByCluster(ctx context.Context, cluster *cluster.ClusterBean) ([]*bean.NodeCapacityDetail, error) GetNodeCapacityDetailByNameAndCluster(ctx context.Context, cluster *cluster.ClusterBean, name string) (*bean.NodeCapacityDetail, error) UpdateNodeManifest(ctx context.Context, request *bean.NodeUpdateRequestDto) (*k8s2.ManifestResponse, error) DeleteNode(ctx context.Context, request *bean.NodeUpdateRequestDto) (*k8s2.ManifestResponse, error) CordonOrUnCordonNode(ctx context.Context, request *bean.NodeUpdateRequestDto) (string, error) DrainNode(ctx context.Context, request *bean.NodeUpdateRequestDto) (string, error) EditNodeTaints(ctx context.Context, request *bean.NodeUpdateRequestDto) (string, error) GetNode(ctx context.Context, clusterId int, nodeName string) (*corev1.Node, error) }
type K8sCapacityServiceImpl ¶
type K8sCapacityServiceImpl struct { K8sUtil *k8s2.K8sUtil // contains filtered or unexported fields }
func NewK8sCapacityServiceImpl ¶
func NewK8sCapacityServiceImpl(Logger *zap.SugaredLogger, clusterService cluster.ClusterService, k8sApplicationService application2.K8sApplicationService, K8sUtil *k8s2.K8sUtil, k8sCommonService k8s.K8sCommonService) *K8sCapacityServiceImpl
func (*K8sCapacityServiceImpl) CordonOrUnCordonNode ¶
func (impl *K8sCapacityServiceImpl) CordonOrUnCordonNode(ctx context.Context, request *bean.NodeUpdateRequestDto) (string, error)
func (*K8sCapacityServiceImpl) DeleteNode ¶
func (impl *K8sCapacityServiceImpl) DeleteNode(ctx context.Context, request *bean.NodeUpdateRequestDto) (*k8s2.ManifestResponse, error)
func (*K8sCapacityServiceImpl) DrainNode ¶
func (impl *K8sCapacityServiceImpl) DrainNode(ctx context.Context, request *bean.NodeUpdateRequestDto) (string, error)
func (*K8sCapacityServiceImpl) EditNodeTaints ¶
func (impl *K8sCapacityServiceImpl) EditNodeTaints(ctx context.Context, request *bean.NodeUpdateRequestDto) (string, error)
func (*K8sCapacityServiceImpl) GetClusterCapacityDetail ¶
func (impl *K8sCapacityServiceImpl) GetClusterCapacityDetail(ctx context.Context, cluster *cluster.ClusterBean, callForList bool) (*bean.ClusterCapacityDetail, error)
func (*K8sCapacityServiceImpl) GetClusterCapacityDetailList ¶
func (impl *K8sCapacityServiceImpl) GetClusterCapacityDetailList(ctx context.Context, clusters []*cluster.ClusterBean) ([]*bean.ClusterCapacityDetail, error)
func (*K8sCapacityServiceImpl) GetNodeCapacityDetailByNameAndCluster ¶
func (impl *K8sCapacityServiceImpl) GetNodeCapacityDetailByNameAndCluster(ctx context.Context, cluster *cluster.ClusterBean, name string) (*bean.NodeCapacityDetail, error)
func (*K8sCapacityServiceImpl) GetNodeCapacityDetailsListByCluster ¶
func (impl *K8sCapacityServiceImpl) GetNodeCapacityDetailsListByCluster(ctx context.Context, cluster *cluster.ClusterBean) ([]*bean.NodeCapacityDetail, error)
func (*K8sCapacityServiceImpl) UpdateNodeManifest ¶
func (impl *K8sCapacityServiceImpl) UpdateNodeManifest(ctx context.Context, request *bean.NodeUpdateRequestDto) (*k8s2.ManifestResponse, error)
Click to show internal directories.
Click to hide internal directories.