predicate

package
v0.0.0-...-bd29076 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package predicate defines Predicates used by Controllers to filter Events before they are provided to EventHandlers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IgnoreDeletionPredicate

type IgnoreDeletionPredicate struct {
	predicate.Funcs
}

IgnoreDeletionPredicate implements a default delete predicate function which always return false.

This predicate will ignore the delete events, if finalizer is being used for delete protection on objects, this predicate is recommended because it will avoid the last invalid reconciliation triggered by delete event.

Controller.Watch(

&source.Kind{Type: v1.MyCustomKind},
&handler.EnqueueRequestForObject{},
predicate.IgnoreDeletionPredicate{},
)

func (IgnoreDeletionPredicate) Delete

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL