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

etcd client: add keepalive #58008

Merged
merged 1 commit into from Jan 17, 2018

Conversation

@rphillips
Copy link
Member

rphillips commented Jan 9, 2018

What this PR does / why we need it: This PR shortens the keepaliveTimeout and enables keepalive within the etcd client to allow the socket to be closed cleanly on a dead etcd server.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #46964

Special notes for your reviewer:

Release note:

NONE

/cc @xiang90

@@ -27,6 +29,11 @@ import (
"k8s.io/apiserver/pkg/storage/value"
)

var (
keepaliveTime = 30 * time.Second

This comment has been minimized.

@hongchaodeng

hongchaodeng Jan 9, 2018

Member

add comments?

This comment has been minimized.

@rphillips

rphillips Jan 9, 2018

Author Member

keepalive intervals and timeouts are pretty well known and the variables are not exported. Is there something that could be cleared up with a comment?

This comment has been minimized.

@xiang90

xiang90 Jan 9, 2018

Contributor

@rphillips we might want to document why we choose an aggressive keepalive timeout than usual minutes level. (there will be only a couple of api servers connected to etcd server as clients. an aggressive timeout can help to detect failure faster without introducing much overheads)

This comment has been minimized.

@rphillips

rphillips Jan 9, 2018

Author Member

added a comment

@xiang90

This comment has been minimized.

Copy link
Contributor

xiang90 commented Jan 9, 2018

/lgtm

/assign @jpbetz @wojtek-t

@rphillips

This comment has been minimized.

Copy link
Member Author

rphillips commented Jan 9, 2018

/test pull-kubernetes-verify

Ryan Phillips

@rphillips rphillips force-pushed the rphillips:fixes/etcd_grpc_keepalive branch from f5d209a to 31ff8c6 Jan 9, 2018

@k8s-merge-robot k8s-merge-robot removed the lgtm label Jan 9, 2018

@rphillips

This comment has been minimized.

Copy link
Member Author

rphillips commented Jan 9, 2018

/assign @jpbetz @wojtek-t

@rphillips

This comment has been minimized.

Copy link
Member Author

rphillips commented Jan 9, 2018

@xiang90 and I work for the same company, and would like to request another reviewer for this PR.

@wojtek-t

This comment has been minimized.

Copy link
Member

wojtek-t commented Jan 10, 2018

I'm fine with that, but I will let others also take a look.

@xiang90

This comment has been minimized.

Copy link
Contributor

xiang90 commented Jan 17, 2018

@jpbetz
kindly ping :)

@jpbetz

jpbetz approved these changes Jan 17, 2018

Copy link
Contributor

jpbetz left a comment

lgtm

@xiang90

This comment has been minimized.

Copy link
Contributor

xiang90 commented Jan 17, 2018

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm label Jan 17, 2018

@k8s-ci-robot

This comment has been minimized.

Copy link
Contributor

k8s-ci-robot commented Jan 17, 2018

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: rphillips, xiang90

Associated issue: #46964

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

@k8s-merge-robot

This comment has been minimized.

Copy link
Contributor

k8s-merge-robot commented Jan 17, 2018

/test all

Tests are more than 96 hours old. Re-running tests.

@xiang90

This comment has been minimized.

Copy link
Contributor

xiang90 commented Jan 17, 2018

/retest

@k8s-merge-robot

This comment has been minimized.

Copy link
Contributor

k8s-merge-robot commented Jan 17, 2018

/test all

Tests are more than 96 hours old. Re-running tests.

@k8s-merge-robot

This comment has been minimized.

Copy link
Contributor

k8s-merge-robot commented Jan 17, 2018

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

@k8s-merge-robot

This comment has been minimized.

Copy link
Contributor

k8s-merge-robot commented Jan 17, 2018

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

@k8s-merge-robot k8s-merge-robot merged commit 75b2109 into kubernetes:master Jan 17, 2018

4 of 13 checks passed

Submit Queue Required Github CI test is not green: pull-kubernetes-bazel-test
Details
pull-kubernetes-bazel-test Job triggered.
Details
pull-kubernetes-e2e-gce Job triggered.
Details
pull-kubernetes-e2e-gce-device-plugin-gpu Job triggered.
Details
pull-kubernetes-e2e-kops-aws Job triggered.
Details
pull-kubernetes-kubemark-e2e-gce Job triggered.
Details
pull-kubernetes-node-e2e Job triggered.
Details
pull-kubernetes-unit Job triggered.
Details
pull-kubernetes-verify Job triggered.
Details
cla/linuxfoundation rphillips authorized
Details
pull-kubernetes-bazel-build Job succeeded.
Details
pull-kubernetes-cross Skipped
pull-kubernetes-e2e-gke-gci Skipped
@k8s-ci-robot

This comment has been minimized.

Copy link
Contributor

k8s-ci-robot commented Jan 17, 2018

@rphillips: The following tests failed, say /retest to rerun them all:

Test name Commit Details Rerun command
pull-kubernetes-unit 31ff8c6 link /test pull-kubernetes-unit
pull-kubernetes-bazel-test 31ff8c6 link /test pull-kubernetes-bazel-test

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment