Repository: kubernetes-sigs/kueue

Issue:
Graduate ManagedJobsNamespaceSelector to GA
This is a very useful feature and I like to discuss what would be needed to graduate this feature to GA.



Discussion:
@kannon92: /assign

Opened up https://github.com/kubernetes-sigs/kueue/pull/5987.@tenzen-y: @kannon92 @mimowo Will we graduate only ManagedJobsNamespaceSelector to GA in v0.13, and drop ManagedJobsNamespaceSelectorAlwaysRespected in v0.14?

https://github.com/kubernetes-sigs/kueue/blob/f4a78e032c0d116860d7dff15d445952a65e6904/keps/3589-manage-jobs-selectively/kep.yaml#L26-L28@mimowo: I prefer to give users more time to provide feedback before GA-ing ManagedJobsNamespaceSelectorAlwaysRespected, so I would suggest 0.15.@tenzen-y: > I prefer to give users more time to provide feedback before GA-ing ManagedJobsNamespaceSelectorAlwaysRespected, so I would suggest 0.15.

SGTM@kannon92: I see them as different features. And given that we are building upon the OP feature I wanted to see if we should graduate this feature.@tenzen-y: > I see them as different features. And given that we are building upon the OP feature I wanted to see if we should graduate this feature.

IIUC, the ManagedJobsNamespaceSelectorAlwaysRespected was introduced for making migraion period.
So, I'm ok with removing it in the v0.15. If @kannon92 want to keep it for a while, it is also ok for me.


Solution patch:
diff --git a/site/content/en/docs/tasks/manage/enforce_job_management/manage_jobs_without_queue_name.md b/site/content/en/docs/tasks/manage/enforce_job_management/manage_jobs_without_queue_name.md
index 52e67047c..83446205e 100644
--- a/site/content/en/docs/tasks/manage/enforce_job_management/manage_jobs_without_queue_name.md
+++ b/site/content/en/docs/tasks/manage/enforce_job_management/manage_jobs_without_queue_name.md
@@ -39,14 +39,6 @@ managedJobsNamespaceSelector:
     kueue.x-k8s.io/managed-namespace: true
 ```
 
-{{< feature-state state="beta" for_version="v0.10" >}}
-{{% alert title="Note" color="primary" %}}
-
-`managedJobsNamespaceSelector` is a Beta feature that is enabled by default.
-
-You can disable it by setting the `ManagedJobsNamespaceSelector` feature gate. Check the [Installation](/docs/installation/#change-the-feature-gates-configuration) guide for details on feature gate configuration.
-{{% /alert %}}
-
 ## Expected Behavior
 
 In all namespaces that match the namespace selector, any Workloads submitted without a `kueue.x-k8s.io/queue-name`
diff --git a/site/content/en/docs/tasks/run/plain_pods.md b/site/content/en/docs/tasks/run/plain_pods.md
index caeaa00e6..99e4087d1 100644
--- a/site/content/en/docs/tasks/run/plain_pods.md
+++ b/site/content/en/docs/tasks/run/plain_pods.md
@@ -48,12 +48,7 @@ This guide is for [batch users](/docs/tasks#batch-user) that have a basic unders
       - "pod"
    ```
 
-{{< feature-state state="beta" for_version="v0.10" >}}
 {{% alert title="Note" color="primary" %}}
-
-`managedJobsNamespaceSelector` is a Beta feature that is enabled by default.
-You can disable it by setting the `ManagedJobsNamespaceSelector` feature gate. Check the [Installation](/docs/installation/#change-the-feature-gates-configuration) guide for details on feature gate configuration.
-
   Prior to Kueue v0.10, the Configuration fields `integrations.podOptions.namespaceSelector`
   and `integrations.podOptions.podSelector` were used instead. The use of `podOptions` was
   deprecated in Kueue v0.11. Users should migrate to using `managedJobsNamespaceSelector`.
diff --git a/site/content/en/docs/tasks/troubleshooting/troubleshooting_pods.md b/site/content/en/docs/tasks/troubleshooting/troubleshooting_pods.md
index 33ae6be4d..b481bdecc 100644
--- a/site/content/en/docs/tasks/troubleshooting/troubleshooting_pods.md
+++ b/site/content/en/docs/tasks/troubleshooting/troubleshooting_pods.md
@@ -29,12 +29,7 @@ A Pod might not have the `kueue.x-k8s.io/managed` due to one of the following re
 4. The Pod doesn't have a `kueue.x-k8s.io/queue-name` label and [`manageJobsWithoutQueueName`](/docs/reference/kueue-config.v1beta1/#Configuration)
    is set to `false`.
 
-{{< feature-state state="beta" for_version="v0.10" >}}
 {{% alert title="Note" color="primary" %}}
-
-`managedJobsNamespaceSelector` is a Beta feature that is enabled by default.
-You can disable it by setting the `ManagedJobsNamespaceSelector` feature gate. Check the [Installation](/docs/installation/#change-the-feature-gates-configuration) guide for details on feature gate configuration.
-
 Prior to Kueue v0.10, the Configuration field `integrations.podOptions.namespaceSelector`
 was used instead. The use of `podOptions` was
 deprecated in Kueue v0.11. Users should migrate to using `managedJobsNamespaceSelector`.
diff --git a/site/content/zh-CN/docs/installation/_index.md b/site/content/zh-CN/docs/installation/_index.md
index 4e6bd9257..1683df251 100644
--- a/site/content/zh-CN/docs/installation/_index.md
+++ b/site/content/zh-CN/docs/installation/_index.md
@@ -288,7 +288,7 @@ spec:
 | `ConfigurableResourceTransformations` | `true`  | Beta  | 0.10  |       |
 | `WorkloadResourceRequestsSummary`     | `false` | Alpha | 0.9   | 0.9   |
 | `WorkloadResourceRequestsSummary`     | `true`  | Beta  | 0.10  | 0.10  |
-| `ManagedJobsNamespaceSelector`        | `true`  | Beta  | 0.10  |       |
+| `ManagedJobsNamespaceSelector`        | `true`  | Beta  | 0.10  | 0.13  |
 | `LocalQueueDefaulting`                | `false` | Alpha | 0.10  | 0.11  |
 | `LocalQueueDefaulting`                | `true`  | Beta  | 0.12  |       |
 | `LocalQueueMetrics`                   | `false` | Alpha | 0.10  |       |
@@ -302,6 +302,7 @@ spec:
 
 | 功能 | 默认值 | 阶段 | 起始版本 | 截止版本 |
 | --------------------------------- | ------- | ---------- | ----- | ----- |
+| `ManagedJobsNamespaceSelector`    | `true`  | GA          | 0.13 |       |
 | `QueueVisibility`                 | `false` | Alpha      | 0.4   | 0.9   |
 | `QueueVisibility`                 | `false` | Deprecated | 0.9   |       |
 | `MultiplePreemptions`             | `false` | Alpha      | 0.8   | 0.8   |
diff --git a/site/content/zh-CN/docs/tasks/manage/enforce_job_management/manage_jobs_without_queue_name.md b/site/content/zh-CN/docs/tasks/manage/enforce_job_management/manage_jobs_without_queue_name.md
index 253017f22..b4c287f9b 100644
--- a/site/content/zh-CN/docs/tasks/manage/enforce_job_management/manage_jobs_without_queue_name.md
+++ b/site/content/zh-CN/docs/tasks/manage/enforce_job_management/manage_jobs_without_queue_name.md
@@ -42,15 +42,6 @@ managedJobsNamespaceSelector:
     kueue.x-k8s.io/managed-namespace: true
 ```
 
-{{< feature-state state="beta" for_version="v0.10" >}}
-{{% alert title="Note" color="primary" %}}
-
-`managedJobsNamespaceSelector` 是一个默认启用的 Beta 特性。
-
-你可以通过设置 `ManagedJobsNamespaceSelector` 特性门控来禁用它。
-查看[安装](/zh-CN/docs/installation/#change-the-feature-gates-configuration)指南以获取关于特性门控配置的详细信息。
-{{% /alert %}}
-
 ## 预期行为
 
 在所有匹配命名空间选择器的命名空间中，任何未带有 `kueue.x-k8s.io/queue-name`
diff --git a/site/content/zh-CN/docs/tasks/run/plain_pods.md b/site/content/zh-CN/docs/tasks/run/plain_pods.md
index caeaa00e6..99e4087d1 100644
--- a/site/content/zh-CN/docs/tasks/run/plain_pods.md
+++ b/site/content/zh-CN/docs/tasks/run/plain_pods.md
@@ -48,12 +48,7 @@ This guide is for [batch users](/docs/tasks#batch-user) that have a basic unders
       - "pod"
    ```
 
-{{< feature-state state="beta" for_version="v0.10" >}}
 {{% alert title="Note" color="primary" %}}
-
-`managedJobsNamespaceSelector` is a Beta feature that is enabled by default.
-You can disable it by setting the `ManagedJobsNamespaceSelector` feature gate. Check the [Installation](/docs/installation/#change-the-feature-gates-configuration) guide for details on feature gate configuration.
-
   Prior to Kueue v0.10, the Configuration fields `integrations.podOptions.namespaceSelector`
   and `integrations.podOptions.podSelector` were used instead. The use of `podOptions` was
   deprecated in Kueue v0.11. Users should migrate to using `managedJobsNamespaceSelector`.
diff --git a/site/content/zh-CN/docs/tasks/troubleshooting/troubleshooting_pods.md b/site/content/zh-CN/docs/tasks/troubleshooting/troubleshooting_pods.md
index 9949ba5f2..c2dd61070 100644
--- a/site/content/zh-CN/docs/tasks/troubleshooting/troubleshooting_pods.md
+++ b/site/content/zh-CN/docs/tasks/troubleshooting/troubleshooting_pods.md
@@ -30,13 +30,7 @@ Pod 可能没有 `kueue.x-k8s.io/managed` 标签的原因如下：
    [`manageJobsWithoutQueueName`](/docs/reference/kueue-config.v1beta1/#Configuration)
    设置为 `false`。
 
-{{< feature-state state="beta" for_version="v0.10" >}}
 {{% alert title="注意" color="primary" %}}
-
-`managedJobsNamespaceSelector` 是一个默认启用的 Beta 特性。
-你可以通过设置 `ManagedJobsNamespaceSelector` 特性门控来禁用它。
-查看[安装](/docs/installation/#change-the-feature-gates-configuration)指南了解特性门控配置的详细信息。
-
 在 Kueue v0.10 之前，使用配置字段 `integrations.podOptions.namespaceSelector`。
 在 Kueue v0.11 中，`podOptions` 的使用被弃用。
 用户应该迁移到使用 `managedJobsNamespaceSelector`。



Test patch:
diff --git a/pkg/controller/jobs/pod/pod_webhook_test.go b/pkg/controller/jobs/pod/pod_webhook_test.go
index 3645a4df0..cc383995d 100644
--- a/pkg/controller/jobs/pod/pod_webhook_test.go
+++ b/pkg/controller/jobs/pod/pod_webhook_test.go
@@ -430,7 +430,7 @@ func TestDefault(t *testing.T) {
 				KueueFinalizer().
 				Obj(),
 		},
-		"ManagedJobsNamespaceSelector is enabled and the namespace matches the selector": {
+		"the namespace matches the selector": {
 			initObjects:                  []client.Object{defaultNamespace},
 			managedJobsNamespaceSelector: defaultManagedJobsNamespaceSelector,
 			pod: testingpod.MakePod("test-pod", defaultNamespace.Name).
@@ -443,7 +443,7 @@ func TestDefault(t *testing.T) {
 				KueueFinalizer().
 				Obj(),
 		},
-		"ManagedJobsNamespaceSelector is enabled but doesn’t match the managedJobsNamespaceSelector": {
+		"doesn’t match the managedJobsNamespaceSelector": {
 			initObjects: []client.Object{
 				utiltesting.MakeNamespaceWrapper("kube-system").Label(corev1.LabelMetadataName, "kube-system").Obj(),
 			},