-
Notifications
You must be signed in to change notification settings - Fork 275
Description
Describe the feature
The fetchAllPods
function currently lists all pods in such a way that it requires etcd to do a quorum read out of all pods in the cluster, and pass that (potentially very large) list to the k8s apiserver, who then selects only the ones with the desired spec.nodeName
field. In very large clusters, this can be slow operation that's arduous for etcd to execute.
A less expensive way of achieving the same thing would be to leverage the apiserver cache, which indexes pods by their node name. This can be done by passing a non-empty ResourceVersion
in the metav1.ListOptions
.
I would like the nthConfig to expose a flag to configure this behavior, with the status quo being the default, since most users seem to be happy with a consistent read.
The situation is very similar to this issue in the vector project, which was fixed by this PR.
Is the feature request related to a problem?
A description of what the problem is. For example: I'm frustrated when [...]
Describe alternatives you've considered
A description of any alternative solutions or features you've considered.