Skip to content

Commit

Permalink
chore: vertex controller stop watching pod create events (numaproj#361)
Browse files Browse the repository at this point in the history
  • Loading branch information
whynowy authored Nov 17, 2022
1 parent 1a5d424 commit 3588bf3
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkg/reconciler/cmd/start.go
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,10 @@ func Start(namespaced bool, managedNamespace string) {
}

// Watch Pods
if err := vertexController.Watch(&source.Kind{Type: &corev1.Pod{}}, &handler.EnqueueRequestForOwner{OwnerType: &dfv1.Vertex{}, IsController: true}); err != nil {
if err := vertexController.Watch(&source.Kind{Type: &corev1.Pod{}}, &handler.EnqueueRequestForOwner{OwnerType: &dfv1.Vertex{}, IsController: true},
predicate.Funcs{
CreateFunc: func(event.CreateEvent) bool { return false }, // Do not watch pod create events
}); err != nil {
logger.Fatalw("Unable to watch Pods", zap.Error(err))
}

Expand Down

0 comments on commit 3588bf3

Please sign in to comment.