Documentation
¶
Overview ¶
Package boxcutter provides a object reconciliation library based on Package Operator.
Index ¶
Constants ¶
const ( // CollisionProtectionPrevent prevents owner collisions entirely // by not allowing to work with objects already present on the cluster. CollisionProtectionPrevent = types.CollisionProtectionPrevent // CollisionProtectionIfNoController allows to patch and override // objects already present if they are not owned by another controller. CollisionProtectionIfNoController = types.CollisionProtectionIfNoController // CollisionProtectionNone allows to patch and override objects already // present and owned by other controllers. // // Be careful! // This setting may cause multiple controllers to fight over a resource, // causing load on the Kubernetes API server and etcd. CollisionProtectionNone = types.CollisionProtectionNone )
const ProgressProbeType = types.ProgressProbeType
ProgressProbeType is a well-known probe type used to guard phase progression.
Variables ¶
var ProbeFunc = types.ProbeFunc
ProbeFunc wraps the given function to work with the Prober interface.
var WithProbe = types.WithProbe
WithProbe registers the given probe to evaluate state of objects.
Functions ¶
This section is empty.
Types ¶
type ObjectOption ¶
type ObjectOption = types.ObjectOption
ObjectOption is the common interface for object reconciliation options.
type OwnerStrategy ¶
type OwnerStrategy interface { SetControllerReference(owner, obj metav1.Object) error GetController(obj metav1.Object) (metav1.OwnerReference, bool) IsController(owner, obj metav1.Object) bool CopyOwnerReferences(objA, objB metav1.Object) ReleaseController(obj metav1.Object) RemoveOwner(owner, obj metav1.Object) }
OwnerStrategy interface needed for RevisionEngine.
type PhaseAccessor ¶
type PhaseAccessor = types.PhaseAccessor
PhaseAccessor represents a collection of objects lifecycled together.
type PhaseObject ¶
type PhaseObject = types.PhaseObject
PhaseObject represents an object and it's options.
type RevisionAccessor ¶
type RevisionAccessor = types.RevisionAccessor
RevisionAccessor represents multiple phases at a given point in time.
type RevisionEngine ¶
type RevisionEngine = machinery.RevisionEngine
RevisionEngine manages rollout and teardown of multiple phases.
func NewRevisionEngine ¶
func NewRevisionEngine(opts RevisionEngineOptions) (*RevisionEngine, error)
NewRevisionEngine returns a new RevisionEngine instance.
type RevisionEngineOptions ¶
type RevisionEngineOptions struct { Scheme *runtime.Scheme FieldOwner string SystemPrefix string DiscoveryClient *discovery.DiscoveryClient RestMapper meta.RESTMapper Writer client.Writer Reader client.Reader OwnerStrategy OwnerStrategy }
RevisionEngineOptions holds all configuration options for the RevisionEngine.
type RevisionEngineOptionsError ¶
type RevisionEngineOptionsError struct {
// contains filtered or unexported fields
}
RevisionEngineOptionsError is returned for errors with the RevisionEngineOptions.
func (RevisionEngineOptionsError) Error ¶
func (e RevisionEngineOptionsError) Error() string
type WithCollisionProtection ¶
type WithCollisionProtection = types.WithCollisionProtection
WithCollisionProtection instructs the given CollisionProtection setting to be used.
type WithPaused ¶
type WithPaused = types.WithPaused
WithPaused skips reconciliation and just reports status information. Can also be described as dry-run, as no modification will occur.
type WithPreviousOwners ¶
type WithPreviousOwners = types.WithPreviousOwners
WithPreviousOwners is a list of known objects allowed to take ownership from. Objects from this list will not trigger collision detection and prevention.
Directories
¶
Path | Synopsis |
---|---|
cmd
|
|
internal
|
|
Package machinery provides object reconciliation strategies for arbitrary kubernetes objects.
|
Package machinery provides object reconciliation strategies for arbitrary kubernetes objects. |
types
Package types contains common type definitions for boxcutter machinery.
|
Package types contains common type definitions for boxcutter machinery. |
Package managedcache implements dynamic cache management to deal with RBAC separation and stopping of informers when they are no longer needed.
|
Package managedcache implements dynamic cache management to deal with RBAC separation and stopping of informers when they are no longer needed. |
Package ownerhandling provides an interface and strategies to handle OwnerReferences.
|
Package ownerhandling provides an interface and strategies to handle OwnerReferences. |
Package boxcutter contains the boxcutter integration test suite.
|
Package boxcutter contains the boxcutter integration test suite. |
Package util contains common utilities for working with boxcutter.
|
Package util contains common utilities for working with boxcutter. |
Package validation contains validators to catch common issues before objects are persisted into the kube-apiserver.
|
Package validation contains validators to catch common issues before objects are persisted into the kube-apiserver. |