Documentation
¶
Overview ¶
Package crdschema contains a controller that rebuilds the shared SSA TypeConverterProvider whenever a relevant CustomResourceDefinition changes.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Provider ¶
type Provider interface {
CRDGroups() map[string]struct{}
IsCRDGroupRelevant(group string) bool
Rebuild(ctx context.Context, logger logr.Logger, crds []*apiextensionsv1.CustomResourceDefinition) error
}
Provider is the subset of *ssa.TypeConverterProvider that Reconciler depends on. Narrowing to an interface keeps this package decoupled from the ssa package's internals and lets tests inject a fake.
type Reconciler ¶
Reconciler watches CustomResourceDefinitions and rebuilds the shared TypeConverterProvider whenever a relevant CRD changes.
func (*Reconciler) Reconcile ¶
Reconcile is called whenever a relevant CRD is added, updated, or deleted. It lists only CRDs in the configured groups from the cache (via field index) and rebuilds the provider's TypeConverter in-process.
func (*Reconciler) SetupWithManager ¶
SetupWithManager registers the reconciler with the manager. The spec.group field index this relies on (see index.OptionsForCRDSchema) is registered centrally by modules/manager.SetupCacheIndexes.