Documentation
¶
Index ¶
- type Manager
- func (m *Manager) AnnotatePodWithPodGroup(pod *corev1.Pod, ms *workloadv1alpha1.ModelServing, groupName, taskName string)
- func (m *Manager) CleanupPodGroups(ctx context.Context, ms *workloadv1alpha1.ModelServing) error
- func (m *Manager) CreateOrUpdatePodGroup(ctx context.Context, ms *workloadv1alpha1.ModelServing, pgName string) (error, time.Duration)
- func (m *Manager) DeletePodGroup(ctx context.Context, ms *workloadv1alpha1.ModelServing, ...) error
- func (m *Manager) GenerateTaskName(roleName string, roleIndex int) string
- func (m *Manager) GetPodGroupInformer() cache.SharedIndexInformer
- func (m *Manager) GetPodGroupLister() volcanoschedulerlister.PodGroupLister
- func (m *Manager) HasPodGroupCRD() bool
- func (m *Manager) Run(parentCtx context.Context) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
CrdInformer cache.SharedIndexInformer
PodGroupInformer cache.SharedIndexInformer
PodGroupLister volcanoschedulerlister.PodGroupLister
// contains filtered or unexported fields
}
Manager manages PodGroups for gang scheduling
func NewManager ¶
func NewManager(kubeClient kubernetes.Interface, volcanoClient volcanoclient.Interface, apiextClient apiextclient.Interface, store datastore.Store, podGroupInformerInitCallback func(cache.SharedIndexInformer)) *Manager
NewManager creates a new gang scheduling manager
func (*Manager) AnnotatePodWithPodGroup ¶
func (m *Manager) AnnotatePodWithPodGroup(pod *corev1.Pod, ms *workloadv1alpha1.ModelServing, groupName, taskName string)
AnnotatePodWithPodGroup annotates a pod with the appropriate PodGroup information
func (*Manager) CleanupPodGroups ¶
func (m *Manager) CleanupPodGroups(ctx context.Context, ms *workloadv1alpha1.ModelServing) error
cleanupPodGroups cleans up all PodGroups for a ModelServing
func (*Manager) CreateOrUpdatePodGroup ¶
func (m *Manager) CreateOrUpdatePodGroup(ctx context.Context, ms *workloadv1alpha1.ModelServing, pgName string) (error, time.Duration)
CreateOrUpdatePodGroup creates a PodGroup for the given ServingGroup if it doesn't exist, or updates it if it does. Returns an error and a requeue duration if there is an error.
func (*Manager) DeletePodGroup ¶
func (m *Manager) DeletePodGroup(ctx context.Context, ms *workloadv1alpha1.ModelServing, servingGroupName string) error
func (*Manager) GenerateTaskName ¶
GenerateTaskName generates task name
func (*Manager) GetPodGroupInformer ¶
func (m *Manager) GetPodGroupInformer() cache.SharedIndexInformer
func (*Manager) GetPodGroupLister ¶
func (m *Manager) GetPodGroupLister() volcanoschedulerlister.PodGroupLister
func (*Manager) HasPodGroupCRD ¶
Click to show internal directories.
Click to hide internal directories.