Documentation ¶
Index ¶
- func CountPodsByPhase(pods []*v1.Pod) map[string]uint32
- func CreateIngress(name string, job *api.Job, pod *v1.Pod, service *v1.Service, ...) *networking.Ingress
- func CreateOwnerReference(pod *v1.Pod) metav1.OwnerReference
- func CreatePod(job *api.Job, defaults *configuration.PodDefaults) *v1.Pod
- func CreatePodFromExecutorApiJob(job *executorapi.JobRunLease, defaults *configuration.PodDefaults) (*v1.Pod, error)
- func CreateService(job *api.Job, pod *v1.Pod, ports []v1.ServicePort, ...) *v1.Service
- func ExtractFailedPodContainerStatuses(pod *v1.Pod, clusterId string) []*armadaevents.ContainerError
- func ExtractIngresses(job *executorapi.JobRunLease, pod *v1.Pod, ...) []*networking.Ingress
- func ExtractJobId(pod *v1.Pod) string
- func ExtractJobIds(pods []*v1.Pod) []string
- func ExtractJobRunId(pod *v1.Pod) string
- func ExtractJobRunIds(pods []*v1.Pod) []string
- func ExtractJobSet(pod *v1.Pod) string
- func ExtractNames(pods []*v1.Pod) []string
- func ExtractNodeNames(nodes []*v1.Node) []string
- func ExtractPodExitCodes(pod *v1.Pod) map[string]int32
- func ExtractPodFailedReason(pod *v1.Pod) string
- func ExtractPodFailureCause(pod *v1.Pod) armadaevents.KubernetesReason
- func ExtractPodKey(pod *v1.Pod) string
- func ExtractPodNumber(pod *v1.Pod) int
- func ExtractQueue(pod *v1.Pod) string
- func ExtractServices(job *executorapi.JobRunLease, pod *v1.Pod) []*v1.Service
- func FilterCompletedPods(pods []*v1.Pod) []*v1.Pod
- func FilterNodes(nodes []*v1.Node, filter func(node *v1.Node) bool) []*v1.Node
- func FilterNonCompletedPods(pods []*v1.Pod) []*v1.Pod
- func FilterPods(pods []*v1.Pod, filter func(*v1.Pod) bool) []*v1.Pod
- func FilterPodsWithPhase(pods []*v1.Pod, podPhase v1.PodPhase) []*v1.Pod
- func FindLastContainerStartTime(pod *v1.Pod) time.Time
- func GenerateIngresses(job *api.Job, pod *v1.Pod, ingressConfig *configuration.IngressConfiguration) ([]*v1.Service, []*networking.Ingress)
- func GetDeletionGracePeriodOrDefault(pod *v1.Pod) time.Duration
- func GetExpectedNumberOfAssociatedIngresses(pod *v1.Pod) int
- func GetExpectedNumberOfAssociatedServices(pod *v1.Pod) int
- func GetManagedPodSelector() labels.Selector
- func GetPodContainerStatuses(pod *v1.Pod) []v1.ContainerStatus
- func GetPodsOnNodes(pods []*v1.Pod, nodes []*v1.Node) []*v1.Pod
- func GetServicePorts(svcConfigs []*IngressServiceConfig, podSpec *v1.PodSpec) []v1.ServicePort
- func GroupByQueue(pods []*v1.Pod) map[string][]*v1.Pod
- func HasCurrentStateBeenReported(pod *v1.Pod) bool
- func HasIngress(pod *v1.Pod) bool
- func HasPodBeenInStateForLongerThanGivenDuration(pod *v1.Pod, duration time.Duration) bool
- func IsInTerminalState(pod *v1.Pod) bool
- func IsManagedPod(pod *v1.Pod) bool
- func IsMarkedForDeletion(pod *v1.Pod) bool
- func IsPodFinishedAndReported(pod *v1.Pod) bool
- func IsReady(node *v1.Node) bool
- func IsReportedDone(pod *v1.Pod) bool
- func IsReportedPreempted(pod *v1.Pod) bool
- func IsReportingPhaseRequired(podPhase v1.PodPhase) bool
- func LastStatusChange(pod *v1.Pod) (time.Time, error)
- func MergeNodeList(list1 []*v1.Node, list2 []*v1.Node) []*v1.Node
- func MergePodList(list1 []*v1.Pod, list2 []*v1.Pod) []*v1.Pod
- func NewTimeExpiringPodCache(expiry time.Duration, cleanUpInterval time.Duration, metricName string) *mapPodCache
- func ProcessItemsWithThreadPool[K any](ctx *armadacontext.Context, maxThreadCount int, itemsToProcess []K, ...)
- func RemoveDuplicates(pods []*v1.Pod) []*v1.Pod
- func RemoveNodesFromList(list1 []*v1.Node, list2 []*v1.Node) []*v1.Node
- func RemovePodsFromList(list1 []*v1.Pod, list2 []*v1.Pod) []*v1.Pod
- func StringUuidsToUuids(uuidStrings []string) ([]*armadaevents.Uuid, error)
- type IngressServiceConfig
- type IngressServiceType
- type PodCache
- type PodStartupStatus
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateIngress ¶
func CreateIngress( name string, job *api.Job, pod *v1.Pod, service *v1.Service, executorIngressConfig *configuration.IngressConfiguration, jobConfig *IngressServiceConfig, ) *networking.Ingress
func CreateOwnerReference ¶
func CreateOwnerReference(pod *v1.Pod) metav1.OwnerReference
func CreatePod ¶
func CreatePod(job *api.Job, defaults *configuration.PodDefaults) *v1.Pod
func CreatePodFromExecutorApiJob ¶ added in v0.3.47
func CreatePodFromExecutorApiJob(job *executorapi.JobRunLease, defaults *configuration.PodDefaults) (*v1.Pod, error)
func CreateService ¶
func CreateService( job *api.Job, pod *v1.Pod, ports []v1.ServicePort, ingSvcType IngressServiceType, useClusterIP bool, ) *v1.Service
func ExtractFailedPodContainerStatuses ¶
func ExtractFailedPodContainerStatuses(pod *v1.Pod, clusterId string) []*armadaevents.ContainerError
func ExtractIngresses ¶ added in v0.3.47
func ExtractIngresses(job *executorapi.JobRunLease, pod *v1.Pod, executorIngressConfig *configuration.IngressConfiguration) []*networking.Ingress
func ExtractJobId ¶
func ExtractJobIds ¶
func ExtractJobRunId ¶ added in v0.3.47
func ExtractJobRunIds ¶ added in v0.3.47
func ExtractJobSet ¶ added in v0.3.50
func ExtractNames ¶
func ExtractNodeNames ¶
func ExtractPodFailedReason ¶
func ExtractPodFailureCause ¶ added in v0.4.36
func ExtractPodFailureCause(pod *v1.Pod) armadaevents.KubernetesReason
func ExtractPodKey ¶
func ExtractPodNumber ¶
func ExtractQueue ¶ added in v0.3.50
func ExtractServices ¶ added in v0.3.47
func ExtractServices(job *executorapi.JobRunLease, pod *v1.Pod) []*v1.Service
func GenerateIngresses ¶
func GenerateIngresses(job *api.Job, pod *v1.Pod, ingressConfig *configuration.IngressConfiguration) ([]*v1.Service, []*networking.Ingress)
func GetDeletionGracePeriodOrDefault ¶
GetDeletionGracePeriodOrDefault returns the pod's DeletionGracePeriodSeconds seconds (if populated) or the K8s default value of 30 seconds (if it isn't)
func GetManagedPodSelector ¶
func GetPodContainerStatuses ¶
func GetPodContainerStatuses(pod *v1.Pod) []v1.ContainerStatus
func GetServicePorts ¶
func GetServicePorts(svcConfigs []*IngressServiceConfig, podSpec *v1.PodSpec) []v1.ServicePort
func GroupByQueue ¶
GroupByQueue Any pod without a queue label set is excluded from the output
func HasIngress ¶
func IsInTerminalState ¶
func IsManagedPod ¶
func IsMarkedForDeletion ¶
func IsReportedDone ¶
func IsReportedPreempted ¶ added in v0.3.57
func NewTimeExpiringPodCache ¶
func ProcessItemsWithThreadPool ¶ added in v0.3.49
func ProcessItemsWithThreadPool[K any](ctx *armadacontext.Context, maxThreadCount int, itemsToProcess []K, processFunc func(K))
func StringUuidsToUuids ¶ added in v0.3.47
func StringUuidsToUuids(uuidStrings []string) ([]*armadaevents.Uuid, error)
Types ¶
type IngressServiceConfig ¶
type IngressServiceConfig struct { Type IngressServiceType Ports []uint32 Annotations map[string]string TlsEnabled bool CertName string UseClusterIp bool }
func CombineIngressService ¶
func CombineIngressService(ingresses []*api.IngressConfig, services []*api.ServiceConfig) []*IngressServiceConfig
type IngressServiceType ¶
type IngressServiceType int
const ( Ingress IngressServiceType = iota NodePort Headless )
func (IngressServiceType) String ¶
func (st IngressServiceType) String() string
type PodStartupStatus ¶
type PodStartupStatus int
Click to show internal directories.
Click to hide internal directories.