Documentation
¶
Index ¶
- func ClusterAndNamespaceIndexFunc(obj any) ([]string, error)
- func ClusterAndNamespaceIndexKey(clusterName logicalcluster.Name, namespace string) string
- func ClusterIndexFunc(obj any) ([]string, error)
- func ClusterIndexKey(clusterName logicalcluster.Name) string
- type ScopedCluster
- func (c *ScopedCluster) GetAPIReader() client.Reader
- func (c *ScopedCluster) GetCache() cache.Cache
- func (c *ScopedCluster) GetClient() client.Client
- func (c *ScopedCluster) GetConfig() *rest.Config
- func (c *ScopedCluster) GetEventRecorderFor(name string) record.EventRecorder
- func (c *ScopedCluster) GetFieldIndexer() client.FieldIndexer
- func (c *ScopedCluster) GetHTTPClient() *http.Client
- func (c *ScopedCluster) GetRESTMapper() meta.RESTMapper
- func (c *ScopedCluster) GetScheme() *runtime.Scheme
- func (c *ScopedCluster) Start(ctx context.Context) error
- type WildcardCache
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ClusterAndNamespaceIndexFunc ¶
ClusterAndNamespaceIndexFunc indexes by cluster and namespace name.
func ClusterAndNamespaceIndexKey ¶
ClusterAndNamespaceIndexKey formats the index key for a cluster name and namespace.
func ClusterIndexFunc ¶
ClusterIndexFunc indexes by cluster name.
func ClusterIndexKey ¶
func ClusterIndexKey(clusterName logicalcluster.Name) string
ClusterIndexKey formats the index key for a cluster name.
Types ¶
type ScopedCluster ¶
type ScopedCluster struct {
// contains filtered or unexported fields
}
ScopedCluster is a cluster that operates on a specific namespace.
func NewScopedCluster ¶
func NewScopedCluster(cfg *rest.Config, clusterName logicalcluster.Name, wildcardCA WildcardCache, scheme *runtime.Scheme) (*ScopedCluster, error)
NewScopedCluster constructs a new cluster.Cluster that operates on a specific logical cluster.
func NewScopedInitializingCluster ¶
func NewScopedInitializingCluster(cfg *rest.Config, clusterName logicalcluster.Name, wildcardCA WildcardCache, scheme *runtime.Scheme) (*ScopedCluster, error)
NewScopedInitializingCluster constructs a new cluster.Cluster that operates on a specific logical cluster for initializing workspaces. It doesn't construct client to read from wildcard cache.
func (*ScopedCluster) GetAPIReader ¶
func (c *ScopedCluster) GetAPIReader() client.Reader
GetAPIReader returns a reader against the cluster.
func (*ScopedCluster) GetCache ¶
func (c *ScopedCluster) GetCache() cache.Cache
GetCache returns a cache.Cache.
func (*ScopedCluster) GetClient ¶
func (c *ScopedCluster) GetClient() client.Client
GetClient returns a client scoped to the namespace.
func (*ScopedCluster) GetConfig ¶
func (c *ScopedCluster) GetConfig() *rest.Config
GetConfig returns the rest.Config scoped to the cluster.
func (*ScopedCluster) GetEventRecorderFor ¶
func (c *ScopedCluster) GetEventRecorderFor(name string) record.EventRecorder
GetEventRecorderFor returns a new EventRecorder for the provided name.
func (*ScopedCluster) GetFieldIndexer ¶
func (c *ScopedCluster) GetFieldIndexer() client.FieldIndexer
GetFieldIndexer returns a FieldIndexer scoped to the cluster.
func (*ScopedCluster) GetHTTPClient ¶
func (c *ScopedCluster) GetHTTPClient() *http.Client
GetHTTPClient returns the HTTP client scoped to the cluster.
func (*ScopedCluster) GetRESTMapper ¶
func (c *ScopedCluster) GetRESTMapper() meta.RESTMapper
GetRESTMapper returns a RESTMapper scoped to the cluster.
func (*ScopedCluster) GetScheme ¶
func (c *ScopedCluster) GetScheme() *runtime.Scheme
GetScheme returns the scheme scoped to the cluster.
type WildcardCache ¶
WildcardCache is a cache that operates on a '/clusters/*' endpoint.
func NewWildcardCache ¶
NewWildcardCache returns a cache.Cache that handles multi-cluster watches against a /clusters/* endpoint. It wires SharedIndexInformers with additional indexes for cluster and cluster+namespace.