Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RefManager ¶
type RefManager struct {
// contains filtered or unexported fields
}
func NewRefManager ¶
func NewRefManager(client client.Writer, selector *metav1.LabelSelector, owner metav1.Object, schema *runtime.Scheme) (*RefManager, error)
func (*RefManager) ClaimObject ¶
ClaimObject tries to take ownership of an object for this controller.
It will reconcile the following:
- Adopt orphans if the match function returns true.
- Release owned objects if the match function returns false.
A non-nil error is returned if some form of reconciliation was attempted and failed. Usually, controllers should try again later in case reconciliation is still needed.
If the error is nil, either the reconciliation succeeded, or no reconciliation was necessary. The returned boolean indicates whether you now own the object.
No reconciliation will be attempted if the controller is being deleted.
func (*RefManager) ClaimOwned ¶
Click to show internal directories.
Click to hide internal directories.