kubernetes / api

The canonical location of the Kubernetes API definition.
Apache License 2.0
652 stars 433 forks source link

The resourceVersion for the provided list is too old #50

Closed JonBruchim closed 8 months ago

JonBruchim commented 1 year ago

Hi

I'm working on a simple application that retrieves a limited list of pods within a particular namespace. However, I occasionally encounter the error message "The resourceVersion for the provided list is too old." It's surprising because the ListPods API doesn't use the "resourceVersion" parameter.

To provide some context, the cluster I'm working with has around 10,000 pods.

Here's an example snippet of my code:

listOptions := metav1.ListOptions{Limit: 1}
pods, err := k.client.CoreV1().Pods(svc.Namespace).List(context.Background(), listOptions)

Could this issue be related to a network problem? I'm wondering if the network latency or potential synchronization issues within the cluster might be causing this error. Any insights or suggestions would be greatly appreciated.

kundan2707 commented 12 months ago

/assign

kundan2707 commented 12 months ago

@JonBruchim Can you provide some detail about your application/pod in which this issue came ?

kundan2707 commented 10 months ago

@JonBruchim gentle reminder

kundan2707 commented 8 months ago

@JonBruchim if there is no issue then you can close this issue.

kundan2707 commented 8 months ago

closing this issue due to no activity. Feel free to open if needed

kundan2707 commented 8 months ago

/close

k8s-ci-robot commented 8 months ago

@kundan2707: Closing this issue.

In response to [this](https://github.com/kubernetes/api/issues/50#issuecomment-1897900978): >/close Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.