Skip to content

Commit 0dbc403

Browse files
murphp15paulm2
andauthored
control-service: remove support for old k8s (#3202)
# Why External customers are looking to run on newer versions of k8s than we support. We are using a very old batch/V1Beta1 api. We need to remove all references to this. # What I deleted all code which was referencing it. This looks like a massive PR but it should actually be fairly simple to review because it is just deleting code. # How was this tested?? Existing unit and integration tests. I will also be deploying it to newer versions of k8s this week. Signed-off-by: murphp15 <murphp15@tcd.ie> --------- Co-authored-by: github-actions <> Co-authored-by: paulm2 <paulm2@vmware.com>
1 parent 5e7024a commit 0dbc403

23 files changed

Lines changed: 83 additions & 870 deletions

projects/control-service/projects/helm_charts/pipelines-control-service/README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@
22
Versatile Data Kit is a platform that enables Data Engineers to implement automated pull ingestion (E in ELT) and batch data transformation into a database (T in ELT).
33

44
## Prerequisites
5-
- Kubernetes 1.19<=x>1.25 works with no config changes
6-
- for kubernetes 1.25+ the datajob template needs to be changed in the [values.yaml](./values.yaml). Specifically `enabled` needs to be set to `true` and `apiVersion` needs to be set to `batch/v1`
5+
- Kubernetes 1.24<
76
- Helm 3.0
87
- PV provisioner support in the underlying infrastructure if using the embedded database.
98
- During helm install - CRUD on Kubernetes Deployment, Service, ServiceAccount, Role, Rolebindings. Control Service itself manages CronJob(Job and Pod as well), Secret resources. Statefulset and PVC if using the embedded database

projects/control-service/projects/helm_charts/pipelines-control-service/values.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -974,7 +974,7 @@ customStartupProbeProbe: {}
974974
datajobTemplate:
975975
enabled: false
976976
template:
977-
apiVersion: batch/v1beta1
977+
apiVersion: batch/v1
978978
kind: CronJob
979979
metadata:
980980
annotations: # merged with additional annotations from TPCS

projects/control-service/projects/pipelines_control_service/src/integration-test/java/com/vmware/taurus/datajobs/it/DataJobDeploymentCrudAsyncIT.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020

2121
@TestPropertySource(
2222
properties = {
23-
"datajobs.control.k8s.k8sSupportsV1CronJob=true",
2423
"datajobs.deployment.configuration.persistence.writeTos=DB",
2524
"datajobs.deployment.configuration.persistence.readDataSource=DB",
2625
"datajobs.deployment.configuration.synchronization.task.enabled=true",

projects/control-service/projects/pipelines_control_service/src/integration-test/java/com/vmware/taurus/datajobs/it/DataJobDeploymentCrudIT.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121

2222
@TestPropertySource(
2323
properties = {
24-
"datajobs.control.k8s.k8sSupportsV1CronJob=true",
2524
"datajobs.deployment.configuration.persistence.writeTos=K8S",
2625
"datajobs.deployment.configuration.persistence.readDataSource=K8S",
2726
"datajobs.deployment.configuration.synchronization.task.enabled=false"

projects/control-service/projects/pipelines_control_service/src/integration-test/java/com/vmware/taurus/datajobs/it/TestJobDeployTempCredsIT.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@
5353
@Import({TestJobDeployTempCredsIT.TaskExecutorConfig.class})
5454
@TestPropertySource(
5555
properties = {
56-
"datajobs.control.k8s.k8sSupportsV1CronJob=true",
5756
"datajobs.aws.assumeIAMRole=true",
5857
"datajobs.aws.RoleArn=arn:aws:iam::320807031117:role/svc.ecr-integration-test",
5958
"datajobs.docker.registryType=ecr",

projects/control-service/projects/pipelines_control_service/src/integration-test/java/com/vmware/taurus/datajobs/it/TestJobImageBuilderDynamicVdkImageIT.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@
4545
@Import({TestJobImageBuilderDynamicVdkImageIT.TaskExecutorConfig.class})
4646
@TestPropertySource(
4747
properties = {
48-
"datajobs.control.k8s.k8sSupportsV1CronJob=true",
4948
"datajobs.deployment.supportedPythonVersions={3.8: {vdkImage:"
5049
+ " 'registry.hub.docker.com/versatiledatakit/quickstart-vdk:pre-release', baseImage:"
5150
+ " 'versatiledatakit/data-job-base-python-3.8:latest', builderImage:"

projects/control-service/projects/pipelines_control_service/src/integration-test/java/com/vmware/taurus/service/deploy/DataJobDeploymentCrudITV2.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@
5151
@Import({DataJobDeploymentCrudITV2.TaskExecutorConfig.class})
5252
@TestPropertySource(
5353
properties = {
54-
"datajobs.control.k8s.k8sSupportsV1CronJob=true",
5554
"datajobs.deployment.configuration.synchronization.task.enabled=true",
5655
"datajobs.deployment.configuration.synchronization.task.initial.delay.ms=1000000",
5756
// Setting this value to 1000000 effectively disables the scheduled execution of

projects/control-service/projects/pipelines_control_service/src/integration-test/resources/application-test.properties

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ datajobs.vdk_options_ini=
1313

1414
datajobs.deployment.k8s.kubeconfig=${DEPLOYMENT_K8S_KUBECONFIG:}
1515
datajobs.deployment.k8s.namespace=${DEPLOYMENT_K8S_NAMESPACE:default}
16-
datajobs.control.k8s.k8sSupportsV1CronJob=false
1716

1817
datajobs.control.k8s.kubeconfig=${CONTROL_K8S_KUBECONFIG:}
1918
datajobs.control.k8s.namespace=${CONTROL_K8S_NAMESPACE:default}

projects/control-service/projects/pipelines_control_service/src/integration-test/resources/data_job_templates/backoff_limit_exceeded_cron_job.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Copyright 2023-2024 Broadcom
22
# SPDX-License-Identifier: Apache-2.0
33

4-
apiVersion: batch/v1beta1
4+
apiVersion: batch/v1
55
kind: CronJob
66
metadata:
77
annotations: # merged with additional annotations from TPCS

projects/control-service/projects/pipelines_control_service/src/integration-test/resources/data_job_templates/fast_failing_cron_job.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Copyright 2023-2024 Broadcom
22
# SPDX-License-Identifier: Apache-2.0
33

4-
apiVersion: batch/v1beta1
4+
apiVersion: batch/v1
55
kind: CronJob
66
metadata:
77
annotations: # merged with additional annotations from TPCS

0 commit comments

Comments
 (0)