Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove tracking annotation from validation and webhooks #117633

Merged

Conversation

kannon92
Copy link
Contributor

@kannon92 kannon92 commented Apr 26, 2023

What type of PR is this?

/kind cleanup

/kind deprecation

What this PR does / why we need it:

In 1.27, we removed the legacy tracking job in the job controller. We no longer check the annotations so we want to now remove validation in 1.28.

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?

remove tracking annotation from validation and defaulting

Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:

-[KEP]: https://github.com/kubernetes/enhancements/tree/master/keps/sig-apps/2307-job-tracking-without-lingering-pods#deprecation

@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. kind/deprecation Categorizes issue or PR as related to a feature/enhancement marked for deprecation. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Apr 26, 2023
@k8s-ci-robot
Copy link
Contributor

This issue is currently awaiting triage.

If a SIG or subproject determines this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added the needs-priority Indicates a PR lacks a `priority/foo` label and requires one. label Apr 26, 2023
@kannon92
Copy link
Contributor Author

/sig apps

@k8s-ci-robot k8s-ci-robot added sig/apps Categorizes an issue or PR as relevant to SIG Apps. and removed do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. labels Apr 26, 2023
@kannon92 kannon92 force-pushed the remove-job-tracking-finalizers branch from 5442468 to a832083 Compare April 26, 2023 17:13
@kannon92 kannon92 force-pushed the remove-job-tracking-finalizers branch from a832083 to 6a4cf35 Compare April 26, 2023 17:16
@kannon92
Copy link
Contributor Author

https://github.com/kubernetes/enhancements/tree/master/keps/sig-apps/2307-job-tracking-without-lingering-pods#deprecation states that we are removing the feature toggle. I also think we should remove the code around validating these annotation or have test cases for it.

@kannon92
Copy link
Contributor Author

/retest

@kannon92
Copy link
Contributor Author

kannon92 commented Apr 28, 2023

@alculquicondor we discussed this offline. Maybe let’s see if this is a good idea to get into this release?

@alculquicondor
Copy link
Member

ref kubernetes/enhancements#2307

Copy link
Member

@alculquicondor alculquicondor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For a change like this, we need to think about it across 2 versions:

  1. If a job is created in k8s v1.28, would it pass update validations in v1.27?

In 1.28, it would be possible to create a job with the annotation, because we completely ignore it from validation. As a result, this annotation can have any value.
The validation in 1.27 allows the annotation on update if it already has it. The value of the annotation is irrelevant.

  1. If a job is created in k8s v1.28, would it behave the same in v1.27?

In v1.27, jobs are created with the annotation (for backwards compatibility with v1.26), but the job controller actually ignores it.
So a job created in v1.28 without the annotation behaves the same in v1.27. We don't care about n-2 skew.

In conclusion, this PR is safe.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 28, 2023
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 0e93836954c5a25da054dc7bafefa21f24bddbde

@alculquicondor
Copy link
Member

/label api-review

@k8s-ci-robot k8s-ci-robot added the api-review Categorizes an issue or PR as actively needing an API review. label Apr 28, 2023
@liggitt liggitt self-assigned this May 4, 2023
@liggitt
Copy link
Member

liggitt commented May 4, 2023

thanks for the detailed reasoning in #117633 (review)

/approve

@liggitt liggitt added this to API review completed, 1.28 in API Reviews May 4, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: alculquicondor, kannon92, liggitt

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 4, 2023
@k8s-ci-robot k8s-ci-robot merged commit 7add692 into kubernetes:master May 4, 2023
1 check passed
@k8s-ci-robot k8s-ci-robot added this to the v1.28 milestone May 4, 2023
@alculquicondor
Copy link
Member

@kannon92 could you update the KEP to reflect that all the deprecation steps where completed? https://github.com/kubernetes/enhancements/tree/master/keps/sig-apps/2307-job-tracking-without-lingering-pods

@kannon92
Copy link
Contributor Author

kannon92 commented May 4, 2023

@kannon92 could you update the KEP to reflect that all the deprecation steps where completed? https://github.com/kubernetes/enhancements/tree/master/keps/sig-apps/2307-job-tracking-without-lingering-pods

Sure thing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api-review Categorizes an issue or PR as actively needing an API review. approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. kind/deprecation Categorizes issue or PR as related to a feature/enhancement marked for deprecation. lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-priority Indicates a PR lacks a `priority/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/apps Categorizes an issue or PR as relevant to SIG Apps. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
Status: API review completed, 1.28
Development

Successfully merging this pull request may close these issues.

None yet

4 participants