File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -7,12 +7,10 @@ package node_observer
77
88import (
99 "context"
10- "time"
1110
1211 corev1 "k8s.io/api/core/v1"
1312 metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
1413 "k8s.io/apimachinery/pkg/labels"
15- "k8s.io/apimachinery/pkg/util/wait"
1614 "k8s.io/client-go/informers"
1715 "k8s.io/client-go/kubernetes"
1816 "k8s.io/client-go/tools/cache"
@@ -78,10 +76,10 @@ func (s *StatusInformer) Start() error {
7876 return err
7977 }
8078
81- go wait . Until ( func () {
79+ go func () {
8280 for s .processEvent () {
8381 }
84- }, time . Second , s . ctx . Done () )
82+ }( )
8583
8684 return nil
8785}
@@ -181,8 +179,8 @@ func (s *StatusInformer) startPodInformer() error {
181179}
182180
183181func (s * StatusInformer ) processEvent () bool {
184- item , quit := s .queue .Get ()
185- if quit {
182+ item , shutdown := s .queue .Get ()
183+ if shutdown {
186184 return false
187185 }
188186 defer s .queue .Done (item )
You can’t perform that action at this time.
0 commit comments