Skip to content

Commit 289ae96

Browse files
committed
chore(operator): Upgrade Kubernetes to v1.34
Signed-off-by: Antonin Stefanutti <antonin@stefanutti.fr>
1 parent 4443f79 commit 289ae96

49 files changed

Lines changed: 3973 additions & 443 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/test-e2e.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
fail-fast: false
1818
matrix:
1919
# Kubernetes versions for e2e tests on Kind cluster.
20-
kubernetes-version: ["1.30.0", "1.31.0", "1.32.3", "1.33.1"]
20+
kubernetes-version: ["1.31.0", "1.32.3", "1.33.1", "1.34.0"]
2121

2222
steps:
2323
- name: Check out code

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ TRAINER_CHART_DIR := $(PROJECT_DIR)/charts/kubeflow-trainer
1818
LOCALBIN ?= $(PROJECT_DIR)/bin
1919

2020
# Tool versions
21-
K8S_VERSION ?= 1.33.0
21+
K8S_VERSION ?= 1.34.0
2222
GINKGO_VERSION ?= $(shell go list -m -f '{{.Version}}' github.com/onsi/ginkgo/v2)
23-
ENVTEST_VERSION ?= release-0.21
23+
ENVTEST_VERSION ?= release-0.22
2424
CONTROLLER_GEN_VERSION ?= v0.18.0
2525
KIND_VERSION ?= $(shell go list -m -f '{{.Version}}' sigs.k8s.io/kind)
2626
HELM_VERSION ?= v3.15.3

api/openapi-spec/swagger.json

Lines changed: 260 additions & 28 deletions
Large diffs are not rendered by default.

api/python_api/kubeflow_trainer_api/models/__init__.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,12 @@
8484
from kubeflow_trainer_api.models.io_k8s_api_core_v1_config_map_projection import IoK8sApiCoreV1ConfigMapProjection
8585
from kubeflow_trainer_api.models.io_k8s_api_core_v1_config_map_volume_source import IoK8sApiCoreV1ConfigMapVolumeSource
8686
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container import IoK8sApiCoreV1Container
87+
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container_extended_resource_request import IoK8sApiCoreV1ContainerExtendedResourceRequest
8788
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container_image import IoK8sApiCoreV1ContainerImage
8889
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container_port import IoK8sApiCoreV1ContainerPort
8990
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container_resize_policy import IoK8sApiCoreV1ContainerResizePolicy
91+
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container_restart_rule import IoK8sApiCoreV1ContainerRestartRule
92+
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container_restart_rule_on_exit_codes import IoK8sApiCoreV1ContainerRestartRuleOnExitCodes
9093
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container_state import IoK8sApiCoreV1ContainerState
9194
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container_state_running import IoK8sApiCoreV1ContainerStateRunning
9295
from kubeflow_trainer_api.models.io_k8s_api_core_v1_container_state_terminated import IoK8sApiCoreV1ContainerStateTerminated
@@ -115,6 +118,7 @@
115118
from kubeflow_trainer_api.models.io_k8s_api_core_v1_event_source import IoK8sApiCoreV1EventSource
116119
from kubeflow_trainer_api.models.io_k8s_api_core_v1_exec_action import IoK8sApiCoreV1ExecAction
117120
from kubeflow_trainer_api.models.io_k8s_api_core_v1_fc_volume_source import IoK8sApiCoreV1FCVolumeSource
121+
from kubeflow_trainer_api.models.io_k8s_api_core_v1_file_key_selector import IoK8sApiCoreV1FileKeySelector
118122
from kubeflow_trainer_api.models.io_k8s_api_core_v1_flex_persistent_volume_source import IoK8sApiCoreV1FlexPersistentVolumeSource
119123
from kubeflow_trainer_api.models.io_k8s_api_core_v1_flex_volume_source import IoK8sApiCoreV1FlexVolumeSource
120124
from kubeflow_trainer_api.models.io_k8s_api_core_v1_flocker_volume_source import IoK8sApiCoreV1FlockerVolumeSource
@@ -190,10 +194,12 @@
190194
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_affinity_term import IoK8sApiCoreV1PodAffinityTerm
191195
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_anti_affinity import IoK8sApiCoreV1PodAntiAffinity
192196
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_attach_options import IoK8sApiCoreV1PodAttachOptions
197+
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_certificate_projection import IoK8sApiCoreV1PodCertificateProjection
193198
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_condition import IoK8sApiCoreV1PodCondition
194199
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_dns_config import IoK8sApiCoreV1PodDNSConfig
195200
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_dns_config_option import IoK8sApiCoreV1PodDNSConfigOption
196201
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_exec_options import IoK8sApiCoreV1PodExecOptions
202+
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_extended_resource_claim_status import IoK8sApiCoreV1PodExtendedResourceClaimStatus
197203
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_ip import IoK8sApiCoreV1PodIP
198204
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_list import IoK8sApiCoreV1PodList
199205
from kubeflow_trainer_api.models.io_k8s_api_core_v1_pod_log_options import IoK8sApiCoreV1PodLogOptions

api/python_api/kubeflow_trainer_api/models/io_k8s_api_batch_v1_job_spec.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class IoK8sApiBatchV1JobSpec(BaseModel):
3131
JobSpec describes how the job execution will look like.
3232
""" # noqa: E501
3333
active_deadline_seconds: Optional[StrictInt] = Field(default=None, description="Specifies the duration in seconds relative to the startTime that the job may be continuously active before the system tries to terminate it; value must be positive integer. If a Job is suspended (at creation or through an update), this timer will effectively be stopped and reset when the Job is resumed again.", alias="activeDeadlineSeconds")
34-
backoff_limit: Optional[StrictInt] = Field(default=None, description="Specifies the number of retries before marking this job failed. Defaults to 6", alias="backoffLimit")
34+
backoff_limit: Optional[StrictInt] = Field(default=None, description="Specifies the number of retries before marking this job failed. Defaults to 6, unless backoffLimitPerIndex (only Indexed Job) is specified. When backoffLimitPerIndex is specified, backoffLimit defaults to 2147483647.", alias="backoffLimit")
3535
backoff_limit_per_index: Optional[StrictInt] = Field(default=None, description="Specifies the limit for the number of retries within an index before marking this index as failed. When enabled the number of failures per index is kept in the pod's batch.kubernetes.io/job-index-failure-count annotation. It can only be set when Job's completionMode=Indexed, and the Pod's restart policy is Never. The field is immutable.", alias="backoffLimitPerIndex")
3636
completion_mode: Optional[StrictStr] = Field(default=None, description="completionMode specifies how Pod completions are tracked. It can be `NonIndexed` (default) or `Indexed`. `NonIndexed` means that the Job is considered complete when there have been .spec.completions successfully completed Pods. Each Pod completion is homologous to each other. `Indexed` means that the Pods of a Job get an associated completion index from 0 to (.spec.completions - 1), available in the annotation batch.kubernetes.io/job-completion-index. The Job is considered complete when there is one successfully completed Pod for each index. When value is `Indexed`, .spec.completions must be specified and `.spec.parallelism` must be less than or equal to 10^5. In addition, The Pod name takes the form `$(job-name)-$(index)-$(random-string)`, the Pod hostname takes the form `$(job-name)-$(index)`. More completion modes can be added in the future. If the Job controller observes a mode that it doesn't recognize, which is possible during upgrades due to version skew, the controller skips updates for the Job. Possible enum values: - `\"Indexed\"` is a Job completion mode. In this mode, the Pods of a Job get an associated completion index from 0 to (.spec.completions - 1). The Job is considered complete when a Pod completes for each completion index. - `\"NonIndexed\"` is a Job completion mode. In this mode, the Job is considered complete when there have been .spec.completions successfully completed Pods. Pod completions are homologous to each other.", alias="completionMode")
3737
completions: Optional[StrictInt] = Field(default=None, description="Specifies the desired number of successfully finished pods the job should be run with. Setting to null means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/")
@@ -40,7 +40,7 @@ class IoK8sApiBatchV1JobSpec(BaseModel):
4040
max_failed_indexes: Optional[StrictInt] = Field(default=None, description="Specifies the maximal number of failed indexes before marking the Job as failed, when backoffLimitPerIndex is set. Once the number of failed indexes exceeds this number the entire Job is marked as Failed and its execution is terminated. When left as null the job continues execution of all of its indexes and is marked with the `Complete` Job condition. It can only be specified when backoffLimitPerIndex is set. It can be null or up to completions. It is required and must be less than or equal to 10^4 when is completions greater than 10^5.", alias="maxFailedIndexes")
4141
parallelism: Optional[StrictInt] = Field(default=None, description="Specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/")
4242
pod_failure_policy: Optional[IoK8sApiBatchV1PodFailurePolicy] = Field(default=None, description="Specifies the policy of handling failed pods. In particular, it allows to specify the set of actions and conditions which need to be satisfied to take the associated action. If empty, the default behaviour applies - the counter of failed pods, represented by the jobs's .status.failed field, is incremented and it is checked against the backoffLimit. This field cannot be used in combination with restartPolicy=OnFailure.", alias="podFailurePolicy")
43-
pod_replacement_policy: Optional[StrictStr] = Field(default=None, description="podReplacementPolicy specifies when to create replacement Pods. Possible values are: - TerminatingOrFailed means that we recreate pods when they are terminating (has a metadata.deletionTimestamp) or failed. - Failed means to wait until a previously created Pod is fully terminated (has phase Failed or Succeeded) before creating a replacement Pod. When using podFailurePolicy, Failed is the the only allowed value. TerminatingOrFailed and Failed are allowed values when podFailurePolicy is not in use. This is an beta field. To use this, enable the JobPodReplacementPolicy feature toggle. This is on by default. Possible enum values: - `\"Failed\"` means to wait until a previously created Pod is fully terminated (has phase Failed or Succeeded) before creating a replacement Pod. - `\"TerminatingOrFailed\"` means that we recreate pods when they are terminating (has a metadata.deletionTimestamp) or failed.", alias="podReplacementPolicy")
43+
pod_replacement_policy: Optional[StrictStr] = Field(default=None, description="podReplacementPolicy specifies when to create replacement Pods. Possible values are: - TerminatingOrFailed means that we recreate pods when they are terminating (has a metadata.deletionTimestamp) or failed. - Failed means to wait until a previously created Pod is fully terminated (has phase Failed or Succeeded) before creating a replacement Pod. When using podFailurePolicy, Failed is the the only allowed value. TerminatingOrFailed and Failed are allowed values when podFailurePolicy is not in use. Possible enum values: - `\"Failed\"` means to wait until a previously created Pod is fully terminated (has phase Failed or Succeeded) before creating a replacement Pod. - `\"TerminatingOrFailed\"` means that we recreate pods when they are terminating (has a metadata.deletionTimestamp) or failed.", alias="podReplacementPolicy")
4444
selector: Optional[IoK8sApimachineryPkgApisMetaV1LabelSelector] = Field(default=None, description="A label query over pods that should match the pod count. Normally, the system sets this field for you. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors")
4545
success_policy: Optional[IoK8sApiBatchV1SuccessPolicy] = Field(default=None, description="successPolicy specifies the policy when the Job can be declared as succeeded. If empty, the default behavior applies - the Job is declared as succeeded only when the number of succeeded pods equals to the completions. When the field is specified, it must be immutable and works only for the Indexed Jobs. Once the Job meets the SuccessPolicy, the lingering pods are terminated.", alias="successPolicy")
4646
suspend: Optional[StrictBool] = Field(default=None, description="suspend specifies whether the Job controller should create Pods or not. If a Job is created with suspend set to true, no Pods are created by the Job controller. If a Job is suspended after creation (i.e. the flag goes from false to true), the Job controller will delete all active Pods associated with this Job. Users must design their workload to gracefully handle this. Suspending a Job will reset the StartTime field of the Job, effectively resetting the ActiveDeadlineSeconds timer too. Defaults to false.")

api/python_api/kubeflow_trainer_api/models/io_k8s_api_batch_v1_success_policy.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class IoK8sApiBatchV1SuccessPolicy(BaseModel):
2727
"""
2828
SuccessPolicy describes when a Job can be declared as succeeded based on the success of some indexes.
2929
""" # noqa: E501
30-
rules: List[IoK8sApiBatchV1SuccessPolicyRule] = Field(description="rules represents the list of alternative rules for the declaring the Jobs as successful before `.status.succeeded >= .spec.completions`. Once any of the rules are met, the \"SucceededCriteriaMet\" condition is added, and the lingering pods are removed. The terminal state for such a Job has the \"Complete\" condition. Additionally, these rules are evaluated in order; Once the Job meets one of the rules, other rules are ignored. At most 20 elements are allowed.")
30+
rules: List[IoK8sApiBatchV1SuccessPolicyRule] = Field(description="rules represents the list of alternative rules for the declaring the Jobs as successful before `.status.succeeded >= .spec.completions`. Once any of the rules are met, the \"SuccessCriteriaMet\" condition is added, and the lingering pods are removed. The terminal state for such a Job has the \"Complete\" condition. Additionally, these rules are evaluated in order; Once the Job meets one of the rules, other rules are ignored. At most 20 elements are allowed.")
3131
__properties: ClassVar[List[str]] = ["rules"]
3232

3333
model_config = ConfigDict(

0 commit comments

Comments
 (0)