Documentation ¶
Index ¶
- type PodSet
- type SchedulingStatus
- type UnitStatus
- type UnitStatusMap
- func (u *UnitStatusMap) AddUnitRunningPods(unitKey string, pods ...*v1.Pod)
- func (u *UnitStatusMap) DeleteUnitRunningPods(unitKey string, pods ...*v1.Pod)
- func (u *UnitStatusMap) DeleteUnitSchedulingStatus(unitKey string)
- func (u *UnitStatusMap) GetUnitRunningPods(unitKey string) []*v1.Pod
- func (u *UnitStatusMap) GetUnitSchedulingStatus(unitKey string) SchedulingStatus
- func (u *UnitStatusMap) GetUnitStatus(unitKey string) UnitStatus
- func (u *UnitStatusMap) SetUnitSchedulingStatus(unitKey string, status SchedulingStatus)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SchedulingStatus ¶
type SchedulingStatus int8
const ( UnknownStatus SchedulingStatus = iota PendingStatus ScheduledStatus TimeoutStatus )
func ParsePodGroupSchedulingStatus ¶
func ParsePodGroupSchedulingStatus(pg *schedulingv1a1.PodGroup) SchedulingStatus
func ParseSinglePodSchedulingStatus ¶
func ParseSinglePodSchedulingStatus(pod *v1.Pod) SchedulingStatus
func (SchedulingStatus) String ¶
func (s SchedulingStatus) String() string
type UnitStatus ¶
type UnitStatus interface { GetSchedulingStatus() SchedulingStatus GetRunningPods() []*v1.Pod }
UnitStatus contains that the scheduling status, running pods and assumed pods. This will be used when we need all the unit's information.
type UnitStatusMap ¶
type UnitStatusMap struct {
// contains filtered or unexported fields
}
UnitStatusMap store the scheduling status, running pods and assumed pods in cache. We need to control the lock of this data structure at the upper level.
func NewUnitStatusMap ¶
func NewUnitStatusMap() *UnitStatusMap
NewUnitStatusMap return a pointer to UnitStatusMap. We need to control the lock of this data structure at the upper level.
func (*UnitStatusMap) AddUnitRunningPods ¶
func (u *UnitStatusMap) AddUnitRunningPods(unitKey string, pods ...*v1.Pod)
func (*UnitStatusMap) DeleteUnitRunningPods ¶
func (u *UnitStatusMap) DeleteUnitRunningPods(unitKey string, pods ...*v1.Pod)
func (*UnitStatusMap) DeleteUnitSchedulingStatus ¶
func (u *UnitStatusMap) DeleteUnitSchedulingStatus(unitKey string)
func (*UnitStatusMap) GetUnitRunningPods ¶
func (u *UnitStatusMap) GetUnitRunningPods(unitKey string) []*v1.Pod
func (*UnitStatusMap) GetUnitSchedulingStatus ¶
func (u *UnitStatusMap) GetUnitSchedulingStatus(unitKey string) SchedulingStatus
func (*UnitStatusMap) GetUnitStatus ¶
func (u *UnitStatusMap) GetUnitStatus(unitKey string) UnitStatus
func (*UnitStatusMap) SetUnitSchedulingStatus ¶
func (u *UnitStatusMap) SetUnitSchedulingStatus(unitKey string, status SchedulingStatus)
Click to show internal directories.
Click to hide internal directories.