kubernetes_asyncio icon indicating copy to clipboard operation
kubernetes_asyncio copied to clipboard

Perform automatic retries for 410s during watches

Open JacobHenner opened this issue 3 years ago • 2 comments

At this time, when a watch expires (with a 410 Gone) the watcher returns an "error" event to the caller. Instead of returning a raw error event, it should attempt to resume the watch (as it would after a timeout). If that fails, it should raise an exception.

A similar change has been incorporated into the kubernetes-client/python library: https://github.com/kubernetes-client/python-base/pull/133

See also:

  • https://github.com/tomplus/kubernetes_asyncio/issues/135
  • https://github.com/tomplus/kubernetes_asyncio/issues/134

JacobHenner avatar Feb 13 '21 22:02 JacobHenner

I'm not sure I still agree with the change proposed originally. I'm going to think about it some more, and will update this issue once I have a better idea of what the desired behavior is (see discussion in the see also links).

JacobHenner avatar Feb 15 '21 04:02 JacobHenner

I ran into this. I am trying to fix the bug, but it is hard to validate a fix since it takes a long time before a 410 gets returned by Kubernetes. An automatic retry in kubernetes-asyncio would be appreciated, especially since the sync kubernetes client has it.

remram44 avatar Feb 07 '22 03:02 remram44