Documentation ¶
Index ¶
- func GetMatcher(selector quotav1.ClusterResourceQuotaSelector) (func(obj runtime.Object) (bool, error), error)
- func GetObjectMatcher(selector quotav1.ClusterResourceQuotaSelector) (func(obj metav1.Object) (bool, error), error)
- func GetResourceQuotasStatusByNamespace(namespaceStatuses quotav1.ResourceQuotasStatusByNamespace, namespace string) (corev1.ResourceQuotaStatus, bool)
- func InsertResourceQuotasStatus(namespaceStatuses *quotav1.ResourceQuotasStatusByNamespace, ...)
- func NewClusterQuotaMapper() *clusterQuotaMapper
- func RemoveResourceQuotasStatusByNamespace(namespaceStatuses *quotav1.ResourceQuotasStatusByNamespace, namespace string)
- type ClusterQuotaMapper
- type ClusterQuotaMappingController
- type MappingChangeListener
- type SelectionFields
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetMatcher ¶
func GetObjectMatcher ¶
func GetResourceQuotasStatusByNamespace ¶
func GetResourceQuotasStatusByNamespace(namespaceStatuses quotav1.ResourceQuotasStatusByNamespace, namespace string) (corev1.ResourceQuotaStatus, bool)
func InsertResourceQuotasStatus ¶
func InsertResourceQuotasStatus(namespaceStatuses *quotav1.ResourceQuotasStatusByNamespace, newStatus quotav1.ResourceQuotaStatusByNamespace)
func NewClusterQuotaMapper ¶
func NewClusterQuotaMapper() *clusterQuotaMapper
func RemoveResourceQuotasStatusByNamespace ¶
func RemoveResourceQuotasStatusByNamespace(namespaceStatuses *quotav1.ResourceQuotasStatusByNamespace, namespace string)
Types ¶
type ClusterQuotaMapper ¶
type ClusterQuotaMapper interface { // GetClusterQuotasFor returns the list of clusterquota names that this namespace matches. It also // returns the selectionFields associated with the namespace for the check so that callers can determine staleness GetClusterQuotasFor(namespaceName string) ([]string, SelectionFields) // GetNamespacesFor returns the list of namespace names that this cluster quota matches. It also // returns the selector associated with the clusterquota for the check so that callers can determine staleness GetNamespacesFor(quotaName string) ([]string, quotav1.ClusterResourceQuotaSelector) AddListener(listener MappingChangeListener) }
type ClusterQuotaMappingController ¶
type ClusterQuotaMappingController struct {
// contains filtered or unexported fields
}
func NewClusterQuotaMappingController ¶
func NewClusterQuotaMappingController(namespaceInformer cache.SharedIndexInformer, quotaInformer cache.SharedIndexInformer, stop <-chan struct{}) *ClusterQuotaMappingController
NewClusterQuotaMappingController builds a mapping between namespaces and ApplicationAwareClusterResourceQuotas
func (*ClusterQuotaMappingController) GetClusterQuotaMapper ¶
func (c *ClusterQuotaMappingController) GetClusterQuotaMapper() ClusterQuotaMapper
func (*ClusterQuotaMappingController) Run ¶
func (c *ClusterQuotaMappingController) Run(workers int)
type MappingChangeListener ¶
type MappingChangeListener interface { AddMapping(quotaName, namespaceName string) RemoveMapping(quotaName, namespaceName string) }
MappingChangeListener is notified of changes to the mapping. It must not block.
type SelectionFields ¶
func GetSelectionFields ¶
func GetSelectionFields(namespace metav1.Object) SelectionFields
Click to show internal directories.
Click to hide internal directories.