Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Custom logger
Functions ¶
func DelegateJob ¶
DelegateJob sends the event to a service's replica
func StartReScheduler ¶
func StartReScheduler(cfg *types.Config, back types.ServerlessBackend, kubeClientset kubernetes.Interface)
StartReScheduler starts the ReScheduler loop to check if there are pending pods exceeding the cfg.ReSchedulerThreshold every cfg.ReSchedulerInterval
func StartResourceManager ¶
func StartResourceManager(rm ResourceManager, interval int)
StartResourceManager starts the ResourceManager loop to check cluster resources every cfg.ResourceManagerInterval
Types ¶
type DelegatedEvent ¶
type DelegatedEvent struct { StorageProviderID string `json:"storage_provider"` Event string `json:"event"` }
DelegatedEvent wraps the original input event by adding the storage provider ID
func WrapEvent ¶
func WrapEvent(providerID string, event string) DelegatedEvent
WrapEvent wraps an event adding the storage_provider field (from the service's cluster_id)
type KubeResourceManager ¶
type KubeResourceManager struct {
// contains filtered or unexported fields
}
KubeResourceManager struct to represent the Kubernetes resource manager
func (*KubeResourceManager) IsSchedulable ¶
func (krm *KubeResourceManager) IsSchedulable(resources v1.ResourceRequirements) bool
IsSchedulable check if a Service's v1.ResourceRequirements can be scheduled in the cluster
func (*KubeResourceManager) UpdateResources ¶
func (krm *KubeResourceManager) UpdateResources() error
UpdateResources update the available resources in the cluster
type ResourceManager ¶
type ResourceManager interface { UpdateResources() error IsSchedulable(v1.ResourceRequirements) bool }
ResourceManager interface to define cluster-level resource managers
func MakeResourceManager ¶
func MakeResourceManager(cfg *types.Config, kubeClientset kubernetes.Interface) ResourceManager
MakeResourceManager returns a new ResourceManager if it is enabled in the config Apache's YuniKorn scheduler not supported yet