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

Back off upon errored kubernetes api requests #2562

Merged
merged 3 commits into from
Jun 6, 2017
Merged

Conversation

rndstr
Copy link
Contributor

@rndstr rndstr commented Jun 5, 2017

fixes #1009

wait := resyncPeriod
for {
func() {
defer runtime.HandleCrash()

This comment was marked as abuse.

This comment was marked as abuse.

@2opremio
Copy link
Contributor

2opremio commented Jun 5, 2017

@rndstr Do you think you could reuse github.com/weaveworks/common/backoff ?

@rndstr
Copy link
Contributor Author

rndstr commented Jun 5, 2017

@2opremio thanks for the suggestion, looks much cleaner now. I also stumbled over an inconsistency regarding logging errors in the backoff code, fix in the common repo: weaveworks/common#42

"io"
"strconv"
"sync"
"time"

log "github.com/Sirupsen/logrus"
"github.com/weaveworks/common/backoff"

This comment was marked as abuse.

@rndstr rndstr merged commit 56cb026 into master Jun 6, 2017
@dlespiau dlespiau deleted the kubernetes-api-backoff branch November 2, 2017 12:29
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.

k8s: Back-off retrying to connect to Kubernetes API
2 participants