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

Fix a regression introduced lately: When any given PodInfraContainer on ... #5466

Merged
merged 1 commit into from
Mar 13, 2015

Conversation

dchen1107
Copy link
Member

...a node

is killed, kubelet kills all remaining containers no matter which pod that
container belongs to.

Fixed #5373

Also updated unittest to reproduce the issue without the fix.

@vmarmol vmarmol self-assigned this Mar 13, 2015
@vmarmol
Copy link
Contributor

vmarmol commented Mar 13, 2015

Needs rebase btw :)

if err != nil {
glog.Errorf("Error listing containers %#v", containersInPod)
return err
}
containersInPod = containers.FindContainersByPod(uid, podFullName)
Copy link
Contributor

Choose a reason for hiding this comment

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

Wow can't believe I missed that...good catch.

@vmarmol
Copy link
Contributor

vmarmol commented Mar 13, 2015

LGTM, just needs a rebase

@dchen1107
Copy link
Member Author

Just verified using the same unittest generated here, earlier refactory of SyncPod introduced this regression, then later one just fixed it. :-) and :-(

Looks like we only need unittests to avoid future breakage. I will double check it against a real cluster and update the PR.

@vmarmol
Copy link
Contributor

vmarmol commented Mar 13, 2015

haha sorry for the churn, the latest refactoring makes things more concrete and easier to follow.

…on a node

is killed, kubelet kills all remaining containers no matter which pod that
container belongs to.

Fixed kubernetes#5373
@dchen1107
Copy link
Member Author

Ok, run tests against the read cluster, the regression is fixed. Updated cl with unnitests only.

@vmarmol
Copy link
Contributor

vmarmol commented Mar 13, 2015

LGTM, thanks @dchen1107! Will merge on green.

vmarmol added a commit that referenced this pull request Mar 13, 2015
Fix a regression introduced lately: When any given PodInfraContainer on ...
@vmarmol vmarmol merged commit b00e82e into kubernetes:master Mar 13, 2015
@thockin
Copy link
Member

thockin commented Mar 16, 2015

I dont get it - this is a no-op change?

@vmarmol
Copy link
Contributor

vmarmol commented Mar 16, 2015

@thockin the real fix was done in #5022 this just adds a test.

@dchen1107
Copy link
Member Author

@thockin The initial PR I sent out does contain a proper fix and unittest reproducing the issue. The regression was introduced by a refactory lately which passes all running k8s containers after killing PodInfraContainers and deciding to kill rest in a given Pod. But at the same day, another refactory code was introduced which fix the initial issue. The only unittest is required then.

@yifan-gu yifan-gu mentioned this pull request Mar 26, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Manually killing one POD container restarts all pods
4 participants