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

wait until all the on going requests go to a stable state before shuti… #2985

Merged
merged 1 commit into from
Oct 14, 2019

Conversation

yyb196
Copy link
Collaborator

@yyb196 yyb196 commented Oct 14, 2019

…ng down daemon

Signed-off-by: shenling.yyb shenling.yyb@alibaba-inc.com

Ⅰ. Describe what this PR did

We must make http requests finish their job or rollback before shutdown pouch daemon, or we will leave container or other object in unpredictable status.

Ⅱ. Does this pull request fix one issue?

none

Ⅲ. Why don't you add test cases (unit test/integration test)? (你真的觉得不需要加测试吗?)

No, I have test inside our environment.

Ⅳ. Describe how to verify it

StartContainer -> CreateEndpoint -> (shutdown)

If we can shutdown daemon at the exact time after CreateEndpoint, it will leave a veth network link on the host before applying this patch.

Ⅴ. Special notes for reviews

…ng down daemon

Signed-off-by: shenling.yyb <shenling.yyb@alibaba-inc.com>
@codecov
Copy link

codecov bot commented Oct 14, 2019

Codecov Report

Merging #2985 into master will decrease coverage by 0.02%.
The diff coverage is 76.92%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2985      +/-   ##
==========================================
- Coverage   68.19%   68.17%   -0.03%     
==========================================
  Files         291      291              
  Lines       18366    18379      +13     
==========================================
+ Hits        12524    12529       +5     
- Misses       4383     4394      +11     
+ Partials     1459     1456       -3
Flag Coverage Δ
#criv1alpha2_test 34.79% <76.92%> (-0.01%) ⬇️
#integration_test_0 36.15% <76.92%> (-0.01%) ⬇️
#integration_test_1 35.55% <76.92%> (-0.01%) ⬇️
#integration_test_2 36.15% <76.92%> (ø) ⬆️
#integration_test_3 35.51% <15.38%> (-0.11%) ⬇️
#node_e2e_test 34.19% <76.92%> (ø) ⬆️
#unittest 27.89% <0%> (-0.03%) ⬇️
Impacted Files Coverage Δ
apis/server/router.go 91.61% <100%> (+0.1%) ⬆️
apis/server/server.go 61.4% <72.72%> (+2.7%) ⬆️
hookplugins/daemonplugin/daemon_hook.go 66.66% <0%> (-33.34%) ⬇️
daemon/daemon.go 67.82% <0%> (-1.99%) ⬇️
ctrd/supervisord/daemon.go 49.32% <0%> (-1.36%) ⬇️
cri/v1alpha2/cri.go 64.09% <0%> (+0.25%) ⬆️
ctrd/container.go 53.55% <0%> (+0.37%) ⬆️

Copy link
Contributor

@fuweid fuweid left a comment

Choose a reason for hiding this comment

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

LGTM

@fuweid fuweid merged commit 53f5b0e into AliyunContainerService:master Oct 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants