Documentation
¶
Index ¶
- Constants
- func CheckFluxCRDs(ctx context.Context, kubeClient client.Client, retryTimeout time.Duration) error
- func GetChildHelmReleases(obj FluxObject) (hrList []string)
- func NewScheme() *runtime.Scheme
- type FluxAdapter
- type FluxObject
- type Node
- type NodeList
- type NodeVisitor
- type ObjEvent
- type ObjectMap
- type TreeInformer
- func (t *TreeInformer) CurrentReconcileDuration(refObj FluxObject, curObj FluxObject) time.Duration
- func (t *TreeInformer) NotifyReconcilableDependents(object FluxObject)
- func (t *TreeInformer) Reconcilable(node Node) bool
- func (t *TreeInformer) Stop()
- func (t *TreeInformer) UpdateObject(fluxObject FluxObject, annotations map[string]string, resume bool)
Constants ¶
View Source
const ( DateFormat = "2006-01-02T15:04:05" ReconcileStartedAnnotation = reconcileAnnotationPrefix + "reconcileStartedAt" ReconcileCompletedAnnotation = reconcileAnnotationPrefix + "reconcileCompletedAt" )
Variables ¶
This section is empty.
Functions ¶
func CheckFluxCRDs ¶
func GetChildHelmReleases ¶
func GetChildHelmReleases(obj FluxObject) (hrList []string)
Special function to retrieve HelmReleases produced by a Kustomization
Types ¶
type FluxAdapter ¶
type FluxObject ¶
type FluxObject interface {
FluxAdapter
QualifiedName() string
DisplayName() string
GetAnnotationValue(annotationName string) string
HasHandledReconcileAnnotation() bool
HasMissingDependencies() bool
GetMissingDependencies() []string
SetMissingDependencies([]string)
Status() string
Ready() bool
Stalled() bool
// contains filtered or unexported methods
}
func NewFluxObject ¶
func NewFluxObject(obj FluxAdapter, defaultNs string) FluxObject
type Node ¶
type Node interface {
FluxObject
GetObject() FluxObject
Reconciled() bool
Watched() bool
// contains filtered or unexported methods
}
type NodeVisitor ¶
type NodeVisitor struct {
// contains filtered or unexported fields
}
func (*NodeVisitor) Visit ¶
func (nv *NodeVisitor) Visit(v dag.Vertexer)
For any edge a -> b (eg. b depends on a), node a will be visited before node b.
type ObjEvent ¶
type ObjEvent struct {
FluxObject
Delete bool
}
type ObjectMap ¶
type ObjectMap interface {
Store(object FluxObject, updateDeps bool) (FluxObject, Node, bool, error)
Remove(object FluxObject) error
Items() NodeList
Get(qualifiedName string) (Node, bool)
SortedWatchedResources() NodeList
ProcessTopologyChange() error
DependsOn(dependent string, dependency string) bool
GetDependencies(nodeName string) NodeList
GetDependents(nodeName string) NodeList
// contains filtered or unexported methods
}
type TreeInformer ¶
type TreeInformer struct {
context.Context
context.CancelFunc
sync.WaitGroup
client.Client
Initialized bool
ReconcileDependents bool
ResumeSuspended bool
ObjectMap
ObjEvents chan ObjEvent
// contains filtered or unexported fields
}
func NewInformer ¶
func (*TreeInformer) CurrentReconcileDuration ¶
func (t *TreeInformer) CurrentReconcileDuration(refObj FluxObject, curObj FluxObject) time.Duration
Returns the duration of current reconcile request, based on reconcile annotations It computes the time elapsed since ReconcileStartedAnnotation of reference object, if it was set with current reconcileID, otherwise it returns 0 If corresponding ReconcileCompletedAnnotation has been set on current object, return the reconcile duration.
func (*TreeInformer) NotifyReconcilableDependents ¶
func (t *TreeInformer) NotifyReconcilableDependents(object FluxObject)
func (*TreeInformer) Reconcilable ¶
func (t *TreeInformer) Reconcilable(node Node) bool
func (*TreeInformer) Stop ¶
func (t *TreeInformer) Stop()
func (*TreeInformer) UpdateObject ¶
func (t *TreeInformer) UpdateObject(fluxObject FluxObject, annotations map[string]string, resume bool)
Click to show internal directories.
Click to hide internal directories.