-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
auto-pause: Using time.Ticker instead of time.Timer to fire idle time-out event. #10700
Conversation
Hi @hetong07. Thanks for your PR. I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. 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. |
Can one of the admins verify this patch? |
@medyagh Do we need to wrap the idleTimer and its parameter check into a helper function? Feel like we can let PR for #10595 to make this decision? Another question is I tried the auto-pause feature, but I notice after 1 minutes only the kubelet stopped, the apiserver is still running, shown below.
This behavior is different than the description in your original PR #10427 , is this behavior intended? |
@hetong07 on my machine it works (mac docker driver) `` $ docker ps
|
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.
Please reset the ticker after each 'unpause' event
@medyagh strange, I repeadly see the API service running, maybe configuration issue?
|
0081f53
to
2683171
Compare
@medyagh @ilya-zuyev why do we need to reset ticker? according to the blog. it should be reset by itself: "It is good to use the ticker timer directly, because the ticker is executed once every certain period of time. Generally, it can be executed multiple times, which is equivalent to calling timer timer time.Reset ." |
I think we have to reset it due to the racing conditions, as @ilya-zuyev stated in previous comments. |
2683171
to
00526e1
Compare
@hetong07: PR needs rebase. 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. |
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.
lgtm, could you rebase this PR and we can merge it
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: hetong07, ilya-zuyev 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 |
/ok-to-test |
@hetong07: The following test failed, say
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. |
@hetong07 Unsure if you're still around, we'd love to merge this PR. We just need it to be rebased! If we don't hear from you in a few days, I may just take ownership of this PR (creating a new PR with the same content). |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
The This bot removes
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /remove-lifecycle frozen |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /close |
@k8s-triage-robot: Closed this PR. In response to this:
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. |
Fix #10596
Using time.Ticker to replace time.Timer to solve the timer memory leak issue. Refer to this blog for more details.