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

Process cluster-scoped owners correctly #57211

Merged
merged 1 commit into from
Dec 15, 2017

Conversation

liggitt
Copy link
Member

@liggitt liggitt commented Dec 14, 2017

Rework of #54943
Fixes #54940

Uses correct scope info from the restmapper at point of object lookup.

Fixed a garbage collection race condition where objects with ownerRefs pointing to cluster-scoped objects could be deleted incorrectly.

@k8s-ci-robot k8s-ci-robot added do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Dec 14, 2017
@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Dec 14, 2017
@liggitt
Copy link
Member Author

liggitt commented Dec 14, 2017

/retest

@liggitt
Copy link
Member Author

liggitt commented Dec 14, 2017

@kubernetes/sig-api-machinery-bugs @kubernetes/sig-api-machinery-pr-reviews

@k8s-ci-robot k8s-ci-robot added sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery. kind/bug Categorizes issue or PR as related to a bug. labels Dec 14, 2017
@liggitt
Copy link
Member Author

liggitt commented Dec 14, 2017

/retest

@ironcladlou
Copy link
Contributor

@caesarxuchao, this essentially implements your suggestion from https://github.com/kubernetes/kubernetes/pull/54943/files#r148858189. @liggitt has some tests incoming later, but this LGTM conceptually.

@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Dec 15, 2017
@liggitt
Copy link
Member Author

liggitt commented Dec 15, 2017

added integration test that delays watch events from the cluster-scoped owner. fails 100% of the time on master. passes 100% of the time on this branch.

@liggitt
Copy link
Member Author

liggitt commented Dec 15, 2017

/retest

@caesarxuchao
Copy link
Member

I skimmed through and it lgtm. I'm OOO until Jan. 3, @ironcladlou could you help review the code? Thanks.

/approve

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 15, 2017
@ironcladlou
Copy link
Contributor

LGTM, very simple approach. Many thanks to @liggitt!

@ironcladlou
Copy link
Contributor

/lgtm

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

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: caesarxuchao, ironcladlou, liggitt

Associated issue: #54940

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

Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@liggitt liggitt added this to the v1.10 milestone Dec 15, 2017
@k8s-cherrypick-bot
Copy link

Removing label cherrypick-candidate because no release milestone was set. This is an invalid state and thus this PR is not being considered for cherry-pick to any release branch. Please add an appropriate release milestone and then re-add the label.

@k8s-github-robot
Copy link

[MILESTONENOTIFIER] Milestone Pull Request Labels Incomplete

@caesarxuchao @ironcladlou @liggitt

Action required: This pull request requires label changes. If the required changes are not made within 2 days, the pull request will be moved out of the v1.9 milestone.

priority: Must specify exactly one of priority/critical-urgent, priority/important-longterm or priority/important-soon.

Help

@enisoc
Copy link
Member

enisoc commented Dec 15, 2017

@liggitt This is targeting 1.9.1, right?

@k8s-github-robot
Copy link

/test all [submit-queue is verifying that this PR is safe to merge]

@liggitt
Copy link
Member Author

liggitt commented Dec 15, 2017

@enisoc yes

@k8s-github-robot
Copy link

Automatic merge from submit-queue (batch tested with PRs 57211, 56150, 56368, 56271, 55957). If you want to cherry-pick this change to another branch, please follow the instructions here.

@k8s-github-robot k8s-github-robot merged commit a0d2337 into kubernetes:master Dec 15, 2017
@liggitt liggitt deleted the gc-cluster-scoped branch December 19, 2017 16:22
k8s-github-robot pushed a commit that referenced this pull request Jan 3, 2018
…1-upstream-release-1.9

Automatic merge from submit-queue.

Automated cherry pick of #57211: Process cluster-scoped owners correctly

Cherry pick of #57211 on release-1.9.

#57211: Process cluster-scoped owners correctly
@k8s-cherrypick-bot
Copy link

Commit found in the "release-1.9" branch appears to be this PR. Removing the "cherrypick-candidate" label. If this is an error find help to get your PR picked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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/bug Categorizes issue or PR as related to a bug. lgtm "Looks good to me", indicates that a PR is ready to be merged. milestone/incomplete-labels release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants