View Source
const (

	// If this finalizer is present on a federated resource, the sync
	// controller will have the opportunity to perform pre-deletion operations
	// (like deleting managed resources from member clusters).
	FinalizerSyncController = ""

	// If this annotation is present on a federated resource, resources in the
	// member clusters managed by the federated resource should be orphaned.
	// If the annotation is not present (the default), resources in member
	// clusters will be deleted before the federated resource is deleted.
	OrphanManagedResources = ""


This section is empty.


func GetOverrideHash

func GetOverrideHash(rawObj *unstructured.Unstructured) (string, error)

func GetTemplateHash

func GetTemplateHash(fieldMap map[string]interface{}) (string, error)

func StartFederationSyncController

func StartFederationSyncController(controllerConfig *util.ControllerConfig, stopChan <-chan struct{}, typeConfig typeconfig.Interface, fedNamespaceAPIResource *metav1.APIResource) error

    StartFederationSyncController starts a new sync controller for a type config


    type FederatedResource

    type FederatedResource interface {
    	FederatedName() util.QualifiedName
    	FederatedKind() string
    	UpdateVersions(selectedClusters []string, versionMap map[string]string) error
    	ComputePlacement(clusters []*fedv1a1.FederatedCluster) (selectedClusters sets.String, err error)
    	IsNamespaceInHostCluster(clusterObj pkgruntime.Object) bool

      FederatedResource encapsulates the behavior of a logical federated resource which may be implemented by one or more kubernetes resources in the cluster hosting the federation control plane.

      type FederatedResourceAccessor

      type FederatedResourceAccessor interface {
      	Run(stopChan <-chan struct{})
      	HasSynced() bool
      	FederatedResource(qualifiedName util.QualifiedName) (federatedResource FederatedResource, possibleOrphan bool, err error)
      	VisitFederatedResources(visitFunc func(obj interface{}))

        FederatedResourceAccessor provides a way to retrieve and visit logical federated resources (e.g. FederatedConfigMap)

        func NewFederatedResourceAccessor

        func NewFederatedResourceAccessor(
        	controllerConfig *util.ControllerConfig,
        	typeConfig typeconfig.Interface,
        	fedNamespaceAPIResource *metav1.APIResource,
        	client genericclient.Client,
        	enqueueObj func(pkgruntime.Object),
        	eventRecorder record.EventRecorder) (FederatedResourceAccessor, error)

        type FederationSyncController

        type FederationSyncController struct {
        	// contains filtered or unexported fields

          FederationSyncController synchronizes the state of a federated type to clusters that are members of the federation.

          func (*FederationSyncController) Run

          func (s *FederationSyncController) Run(stopChan <-chan struct{})


          Path Synopsis