When the code tries to get a lease, it contacts kube-api. If dor some reason, the connectivity failed, flanneld will error out and the registration of the network will fail. This PR makes it try several times before really failing so that we can be more resilient.
This PR also replaces some wait.Poll() calls. That one is deprecated
Todos
[ ] Tests
[ ] Documentation
[ ] Release note
Release Note
Retry contacting kube-api when acquiring a lease if it fails
Description
When the code tries to get a lease, it contacts kube-api. If dor some reason, the connectivity failed, flanneld will error out and the registration of the network will fail. This PR makes it try several times before really failing so that we can be more resilient.
This PR also replaces some wait.Poll() calls. That one is deprecated
Todos
Release Note