From 0f68654123cb67279469510ee84bb019fefe35ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Wo=C5=BAniak?= Date: Thu, 21 Dec 2023 12:09:45 +0100 Subject: [PATCH] Review remarks --- keps/prod-readiness/sig-apps/4368.yaml | 2 - .../README.md | 272 +----------------- 2 files changed, 5 insertions(+), 269 deletions(-) diff --git a/keps/prod-readiness/sig-apps/4368.yaml b/keps/prod-readiness/sig-apps/4368.yaml index f39e0ba2ed7f..af9b8f9a595d 100644 --- a/keps/prod-readiness/sig-apps/4368.yaml +++ b/keps/prod-readiness/sig-apps/4368.yaml @@ -1,5 +1,3 @@ kep-number: 4368 -alpha: - approver: "@wojtek-t" beta: approver: "@wojtek-t" diff --git a/keps/sig-apps/4368-support-managed-by-label-for-batch-jobs/README.md b/keps/sig-apps/4368-support-managed-by-label-for-batch-jobs/README.md index 34d72e1db786..2c8ee95aa7ce 100644 --- a/keps/sig-apps/4368-support-managed-by-label-for-batch-jobs/README.md +++ b/keps/sig-apps/4368-support-managed-by-label-for-batch-jobs/README.md @@ -1,81 +1,5 @@ - # KEP-4368: Support managed-by label for Jobs - - - - - [Release Signoff Checklist](#release-signoff-checklist) - [Summary](#summary) @@ -170,32 +94,13 @@ Items marked with (R) are required *prior to targeting to a milestone / release* ## Summary - - We support the `managed-by` label as a lightweight mechanism to delegate the Job synchronization to an external controller. ## Motivation As a part of [Kueue](https://github.com/kubernetes-sigs) (an effort done by -Batch-WG, in cooperation with SIG-Autoscaling, SIG-Scheduling and SIG-Apps) we +Batch-WG, in cooperation with SIG-Node, SIG-Autoscaling, SIG-Scheduling and SIG-Apps) we are working on a multi-cluster job dispatcher project, called [MultiKueue](https://github.com/kubernetes-sigs/kueue/pull/1380). @@ -208,56 +113,21 @@ of the Job created by the user. In order to support this workflow we need a mechanism to disable the main Job controller, and delegate the status synchronization to the Kueue controller. - - ### Goals - - - support delegation of Job synchronization to an external controller ### Non-Goals - - - passing custom parameters to the external controller ## Proposal - - The proposal is to support the `managed-by` label to disabled the Job controller from synchronizing jobs with the annotation. ### User Stories (Optional) - - #### Story 1 As a developer of Kueue I want to have Job API which allows me to implement the @@ -322,13 +192,6 @@ portion of jobs would require an actual etcd write after cluster upgrade. We add evaluation of the strategy to [GA requirements](#ga). - - ### Risks and Mitigations #### Ecosystem fragmentation due to forks @@ -345,27 +208,8 @@ control plane can disable by passing `controllers=-job,*` in the manifest for of Second, we believe that users who had the need to fork the Job controller already introduced dedicated Job CRDs for their needs. - - ## Design Details - - #### API ```golang @@ -383,74 +227,24 @@ In the [Beta](#beta) iteration of the feature we skip synchronization of the Jobs with the `managed-by` label, if it has any different value than `job-controller`. We also default the label for all newly created jobs, to avoid implicit defaults. -There is no validation for the values of the field. +There is no validation for the values of the field beyond that of standard permitted label values. ### Test Plan - - [x] I/we understand the owners of the involved components may require updates to existing tests to make this code solid enough prior to committing the changes necessary to implement this enhancement. ##### Prerequisite testing updates - - ##### Unit tests - - - - - `pkg/controller/job`: `2023-12-20` - `91.5%` - `pkg/registry/batch/job`: `2023-12-20` - `92.2%` - `pkg/apis/batch/v1`: `2023-12-20` - `29.3%` (mostly generated code) ##### Integration tests - - - - The following scenarios are covered: - a new created job has the `managed-by` label defaulted to `job-controller` - the Job controller reconciles jobs with the `managed-by` label equal to `job-controller` @@ -461,70 +255,14 @@ During the implementation more scenarios might be covered. ##### e2e tests - - -The following scenarios are covered: +We propose a single e2e test for the following scenario: - the Job controller does not reconcile a job with any other value of the `managed-by` label ### Graduation Criteria - - #### Beta - skip synchronization of jobs when the `managed-by` label does not exist, or equals `job-controller`