Documentation
¶
Index ¶
- Constants
- type NodeResourceManager
- func (o *NodeResourceManager) BuildNodeStatus(node *v1.Node) map[string]int64
- func (o *NodeResourceManager) FindTargetNode(tsp *predictionapi.TimeSeriesPrediction, addresses []v1.NodeAddress) (bool, error)
- func (o *NodeResourceManager) GetCanNotBeReclaimedResourceFromLocal() map[v1.ResourceName]float64
- func (o *NodeResourceManager) GetCanNotBeReclaimedResourceFromTsp(node *v1.Node) map[v1.ResourceName]float64
- func (o *NodeResourceManager) GetCpuCoreCanNotBeReclaimedFromLocal() float64
- func (o *NodeResourceManager) GetMemCanNotBeReclaimedFromLocal() float64
- func (o *NodeResourceManager) Name() string
- func (o *NodeResourceManager) Run(stop <-chan struct{})
- func (o *NodeResourceManager) UpdateNodeResource()
- type PodResourceManager
- type ReserveResource
Constants ¶
View Source
const ( MinDeltaRatio = 0.1 StateExpiration = 1 * time.Minute TspUpdateInterval = 20 * time.Second NodeReserveResourcePercentageAnnotationPrefix = "reserve.node.gocrane.io/%s" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type NodeResourceManager ¶
type NodeResourceManager struct {
// contains filtered or unexported fields
}
func NewNodeResourceManager ¶
func NewNodeResourceManager(client clientset.Interface, nodeName string, nodeResourceReserved map[string]string, tspName string, nodeInformer coreinformers.NodeInformer, tspInformer predictionv1.TimeSeriesPredictionInformer, stateChann chan map[string][]common.TimeSeries) (*NodeResourceManager, error)
func (*NodeResourceManager) BuildNodeStatus ¶
func (o *NodeResourceManager) BuildNodeStatus(node *v1.Node) map[string]int64
func (*NodeResourceManager) FindTargetNode ¶
func (o *NodeResourceManager) FindTargetNode(tsp *predictionapi.TimeSeriesPrediction, addresses []v1.NodeAddress) (bool, error)
func (*NodeResourceManager) GetCanNotBeReclaimedResourceFromLocal ¶ added in v0.5.0
func (o *NodeResourceManager) GetCanNotBeReclaimedResourceFromLocal() map[v1.ResourceName]float64
func (*NodeResourceManager) GetCanNotBeReclaimedResourceFromTsp ¶ added in v0.5.0
func (o *NodeResourceManager) GetCanNotBeReclaimedResourceFromTsp(node *v1.Node) map[v1.ResourceName]float64
func (*NodeResourceManager) GetCpuCoreCanNotBeReclaimedFromLocal ¶ added in v0.5.0
func (o *NodeResourceManager) GetCpuCoreCanNotBeReclaimedFromLocal() float64
func (*NodeResourceManager) GetMemCanNotBeReclaimedFromLocal ¶ added in v0.8.0
func (o *NodeResourceManager) GetMemCanNotBeReclaimedFromLocal() float64
func (*NodeResourceManager) Name ¶
func (o *NodeResourceManager) Name() string
func (*NodeResourceManager) Run ¶
func (o *NodeResourceManager) Run(stop <-chan struct{})
func (*NodeResourceManager) UpdateNodeResource ¶
func (o *NodeResourceManager) UpdateNodeResource()
type PodResourceManager ¶
func NewPodResourceManager ¶
func NewPodResourceManager(client clientset.Interface, nodeName string, podInformer coreinformers.PodInformer, runtimeEndpoint string, stateChann chan map[string][]common.TimeSeries, cadvisorManager cadvisor.Manager) *PodResourceManager
func (*PodResourceManager) Name ¶
func (o *PodResourceManager) Name() string
func (*PodResourceManager) Run ¶
func (o *PodResourceManager) Run(stop <-chan struct{})
type ReserveResource ¶ added in v0.5.0
ReserveResource is the cpu and memory reserve configuration
Click to show internal directories.
Click to hide internal directories.