Documentation ¶
Index ¶
- Constants
- func AddStaticResourceScope(gk schema.GroupKind, namespaced bool)
- func CreateObjectsInventory(namespace, name string, objects []runtime.Object) (*core.ConfigMap, error)
- func GetObjectsFromInventory(inventory core.ConfigMap) (objects []runtime.Object)
- type Inventory
- func (i *Inventory) Append(namespace, component string, parent reconciler.ResourceOwner, ...) ([]reconciler.ResourceBuilder, error)
- func (c *Inventory) IsClusterScoped(obj runtime.Object) (bool, error)
- func (c *Inventory) PrepareDeletableObjects() error
- func (c *Inventory) PrepareDesiredObjects(ns, componentName string, parent reconciler.ResourceOwner, ...) (*core.ConfigMap, error)
- func (c *Inventory) TypesToPurge() []schema.GroupVersionKind
- type InventoryData
Constants ¶
View Source
const ( CustomResourceDefinition = "CustomResourceDefinition" Namespace = "Namespace" )
Variables ¶
This section is empty.
Functions ¶
func AddStaticResourceScope ¶
func CreateObjectsInventory ¶
Types ¶
type Inventory ¶
type Inventory struct {
// contains filtered or unexported fields
}
A generalized structure to enable us to attach additional inventory management around the native reconcile loop and adds the capability to store state between reconcile phases (see operator-tool's NativeReconciler)
func NewDiscoveryInventory ¶
func NewInventory ¶
func (*Inventory) Append ¶
func (i *Inventory) Append(namespace, component string, parent reconciler.ResourceOwner, resourceBuilders []reconciler.ResourceBuilder) ([]reconciler.ResourceBuilder, error)
func (*Inventory) IsClusterScoped ¶
IsClusterScoped returns true of the type if the specified resource is of cluster scope. It returns false for namespace scoped resources.
func (*Inventory) PrepareDeletableObjects ¶
Collect `missing` resources from desired state
func (*Inventory) PrepareDesiredObjects ¶
func (c *Inventory) PrepareDesiredObjects(ns, componentName string, parent reconciler.ResourceOwner, resourceBuilders []reconciler.ResourceBuilder) (*core.ConfigMap, error)
Fetch list of resources made by the previous reconcile loop and store into an attached context Return a new list of resources which will be reconciled among with the other resources we listed here
func (*Inventory) TypesToPurge ¶
func (c *Inventory) TypesToPurge() []schema.GroupVersionKind
Hand over a GVK list to the native reconcile loop's purge method
Click to show internal directories.
Click to hide internal directories.