Documentation
¶
Index ¶
- type TemplateCacheFetchResult
- type TemplateCacheObservation
- type TemplateCacheReconciler
- func (r *TemplateCacheReconciler) ComposeState(ctx context.Context, ...) TemplateCacheObservation
- func (r *TemplateCacheReconciler) DecorateStatus(status *aimv1alpha1.AIMTemplateCacheStatus, ...)
- func (r *TemplateCacheReconciler) FetchRemoteState(ctx context.Context, c client.Client, ...) TemplateCacheFetchResult
- func (r *TemplateCacheReconciler) PlanResources(ctx context.Context, ...) controllerutils.PlanResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TemplateCacheFetchResult ¶
type TemplateCacheFetchResult struct {
// contains filtered or unexported fields
}
func (TemplateCacheFetchResult) GetComponentHealth ¶
func (result TemplateCacheFetchResult) GetComponentHealth() []controllerutils.ComponentHealth
GetComponentHealth returns the health of all dependencies for status computation.
type TemplateCacheObservation ¶
type TemplateCacheObservation struct {
TemplateCacheFetchResult
AllCachesAvailable bool
MissingCaches []aimv1alpha1.AIMModelSource
BestArtifacts map[string]aimv1alpha1.AIMArtifact
}
func (TemplateCacheObservation) GetComponentHealth ¶
func (obs TemplateCacheObservation) GetComponentHealth() []controllerutils.ComponentHealth
GetComponentHealth overrides the embedded FetchResult's method to include artifact health. This is necessary because cache matching happens in ComposeState, which runs after FetchRemoteState.
type TemplateCacheReconciler ¶
type TemplateCacheReconciler struct {
Clientset kubernetes.Interface
Scheme *runtime.Scheme
}
func (*TemplateCacheReconciler) ComposeState ¶
func (r *TemplateCacheReconciler) ComposeState( ctx context.Context, reconcileCtx controllerutils.ReconcileContext[*aimv1alpha1.AIMTemplateCache], fetch TemplateCacheFetchResult, ) TemplateCacheObservation
func (*TemplateCacheReconciler) DecorateStatus ¶
func (r *TemplateCacheReconciler) DecorateStatus( status *aimv1alpha1.AIMTemplateCacheStatus, cm *controllerutils.ConditionManager, obs TemplateCacheObservation, )
DecorateStatus implements StatusDecorator to populate status fields and set domain-specific conditions. The framework will set the overall Ready condition after this runs, based on all conditions.
NOTE: This method sets the ArtifactsReady condition (rather than GetComponentHealth) because cache health depends on matching logic computed in ComposeState - specifically which caches match the template's ModelSources. See GetComponentHealth for more context.
func (*TemplateCacheReconciler) FetchRemoteState ¶
func (r *TemplateCacheReconciler) FetchRemoteState( ctx context.Context, c client.Client, reconcileCtx controllerutils.ReconcileContext[*aimv1alpha1.AIMTemplateCache], ) TemplateCacheFetchResult
func (*TemplateCacheReconciler) PlanResources ¶
func (r *TemplateCacheReconciler) PlanResources( ctx context.Context, reconcileCtx controllerutils.ReconcileContext[*aimv1alpha1.AIMTemplateCache], obs TemplateCacheObservation, ) controllerutils.PlanResult