File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -124,7 +124,10 @@ func (ds *K8sDatastore) LabelsMatch(podLabels map[string]string) bool {
124
124
125
125
func (ds * K8sDatastore ) flushPodsAndRefetch (ctx context.Context , ctrlClient client.Client , newServerPool * v1alpha1.InferencePool ) {
126
126
podList := & corev1.PodList {}
127
- if err := ctrlClient .List (ctx , podList , selectorFromInferencePoolSelector (newServerPool .Spec .Selector ).(client.MatchingLabelsSelector )); err != nil {
127
+ if err := ctrlClient .List (ctx , podList , & client.ListOptions {
128
+ LabelSelector : selectorFromInferencePoolSelector (newServerPool .Spec .Selector ),
129
+ Namespace : newServerPool .Namespace ,
130
+ }); err != nil {
128
131
klog .Error (err , "error listing clients" )
129
132
}
130
133
podMap := sync.Map {}
You can’t perform that action at this time.
0 commit comments