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
Roll-forward: Beta requirements for JobTrackingWithFinalizers #105197
Conversation
/hold |
/remove-sig instrumentation testing |
ed9af1d
to
1c1c148
Compare
1c1c148
to
a66aa4b
Compare
To potentially reduce the number of job controller syncs. Also reduce the maximum number of pods to sync in tests.
a66aa4b
to
ac51722
Compare
I will proceed to rerun integration tests a few times to spot flakiness /test pull-kubernetes-integration |
3rd run |
4th run |
5th run |
/hold cancel |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/triage accepted
/priority backlog
/lgtm
/approve
pkg/controller/job/job_controller.go
Outdated
var err error | ||
if needsFlush { | ||
if job, err = jm.updateStatusHandler(job); err != nil { | ||
return job, needsFlush, fmt.Errorf("adding uncounted pods to status: %w", err) | ||
} | ||
recordJobPodFinished(job, *oldCounters) | ||
// Shallow copy. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: explain why it's sufficient for shallow copy rather than just stating it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/hold
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: alculquicondor, soltysh 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 |
Add the UIDs of Pods for which we are removing finalizers to an in-memory cache. The controller removes UIDs from the cache as Pod updates or deletes come in. This avoids double counting finished Pods when Pod updates arrive after Job status updates. kubernetes#105200
ac51722
to
5929ccd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/hold cancel
/retest |
/lgtm |
The Kubernetes project has merge-blocking tests that are currently too flaky to consistently pass. This bot retests PRs for certain kubernetes repos according to the following rules:
You can:
/retest |
What type of PR is this?
/kind feature
/sig apps
What this PR does / why we need it:
Satisfies beta requirements for JobTrackingWithFinalizers (but it doesn't graduate the feature gate yet):
job_pod_finished_total
, which increments when the job controller finished tracking a pod (finalizer removed and pod accounted in status counters)Which issue(s) this PR fixes:
Ref kubernetes/enhancements#2307
Fixes #105200
Special notes for your reviewer:
This is roll-forward of #104739, reverted in #105181. Commits 2 and 3 are a direct revert of #105181.
The remaining commits include the fixes to the flakiness. The main changes are:
Does this PR introduce a user-facing change?
dropped release note with revert in #105181
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.: