Skip to content

Commit 8f6b617

Browse files
committed
review remarks
1 parent 47490b8 commit 8f6b617

File tree

1 file changed

+24
-1
lines changed
  • content/en/docs/concepts/workloads/controllers

1 file changed

+24
-1
lines changed

content/en/docs/concepts/workloads/controllers/job.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1010,6 +1010,12 @@ status:
10101010
10111011
{{< feature-state for_k8s_version="v1.30" state="alpha" >}}
10121012
1013+
{{< note >}}
1014+
You can only set `ManagedBy` field on Jobs if you enable the `JobManagedBy`
1015+
[feature gate](/docs/reference/command-line-tools-reference/feature-gates/)
1016+
(disabled by default).
1017+
{{< /note >}}
1018+
10131019
This feature allows you to disable the built-in Job controller, for a specific
10141020
Job, and delegate reconciliation of the Job to an external controller.
10151021

@@ -1023,10 +1029,27 @@ installed, otherwise the Job may not be reconciled at all.
10231029
{{< /note >}}
10241030

10251031
{{< note >}}
1026-
When developing an external Job controller make sure it does not use the
1032+
When developing an external Job controller be aware that your controller needs
1033+
to operate in a fashion conformant with the definitions of the API spec and
1034+
status fields of the Job object.
1035+
1036+
Please review these in detail the [Job API](/docs/reference/kubernetes-api/workload-resources/job-v1/).
1037+
We also recommend you running the e2e conformance tests for the Job object to
1038+
verify your implementation.
1039+
1040+
Finally, when developing an external Job controller make sure it does not use the
10271041
`batch.kubernetes.io/job-tracking` finalizer, reserved for the built-in controller.
10281042
{{< /note >}}
10291043

1044+
{{< warning >}}
1045+
If you are considering to disable the `JobManagedBy` feature gate, or to
1046+
downgrade the cluster to a version without the feature gate enabled, inspect
1047+
there are no jobs with a custom value of the `spec.managedBy` field. If there
1048+
are such jobs, there is a risk that they might be reconciled by two controllers
1049+
after the operation: the built-in Job controller and the external controller
1050+
indicated by the field value.
1051+
{{< /warning >}}
1052+
10301053
## Alternatives
10311054

10321055
### Bare Pods

0 commit comments

Comments
 (0)