diff --git a/controllers/crds/cninode_controller.go b/controllers/crds/cninode_controller.go index a1bb1332..6d1803cd 100644 --- a/controllers/crds/cninode_controller.go +++ b/controllers/crds/cninode_controller.go @@ -202,10 +202,10 @@ func (r *CNINodeReconciler) SetupWithManager(mgr ctrl.Manager) error { func (r *CNINodeReconciler) waitTillCNINodeDeleted(ctx context.Context, nameSpacedCNINode types.NamespacedName) error { oldCNINode := &v1alpha1.CNINode{} - ctx, cancel := context.WithTimeout(context.TODO(), time.Second*10) + ctx, cancel := context.WithTimeout(context.TODO(), time.Second*3) defer cancel() - return wait.PollUntilContextCancel(ctx, time.Second, true, func(ctx context.Context) (bool, error) { + return wait.PollUntilContextCancel(ctx, 500*time.Millisecond, true, func(ctx context.Context) (bool, error) { if err := r.Client.Get(ctx, nameSpacedCNINode, oldCNINode); err != nil { if errors.IsNotFound(err) { return true, nil diff --git a/pkg/config/type.go b/pkg/config/type.go index 6b08515b..5bf58a57 100644 --- a/pkg/config/type.go +++ b/pkg/config/type.go @@ -52,7 +52,7 @@ const ( // OSLinux is the the linux Operating System OSLinux = "linux" // Node termination finalizer on CNINode CRD - NodeTerminationFinalizer = "node.k8s.aws.com/termination" + NodeTerminationFinalizer = "networking.k8s.aws/node-termination" ) // EC2 Tags