Documentation ¶
Index ¶
- type Manager
- func (m *Manager) GetSecret(namespace, routeName string) (*v1.Secret, error)
- func (m *Manager) Queue() workqueue.RateLimitingInterface
- func (m *Manager) RegisterRoute(ctx context.Context, namespace, routeName, secretName string) error
- func (m *Manager) UnregisterRoute(namespace, routeName string) error
- func (m *Manager) WithSecretHandler(handler cache.ResourceEventHandlerFuncs) *Manager
- type ObjectKey
- type SecretEventHandlerRegistration
- type SecretMonitor
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
func NewManager ¶
func NewManager(kubeClient *kubernetes.Clientset, queue workqueue.RateLimitingInterface) *Manager
func (*Manager) Queue ¶
func (m *Manager) Queue() workqueue.RateLimitingInterface
func (*Manager) RegisterRoute ¶
func (*Manager) UnregisterRoute ¶
func (*Manager) WithSecretHandler ¶
func (m *Manager) WithSecretHandler(handler cache.ResourceEventHandlerFuncs) *Manager
type ObjectKey ¶
type ObjectKey struct { // Namespace is the namespace in which the resource is located. Namespace string // Name denotes metadata.name of a resource being monitored by informer Name string }
ObjectKey represents the unique identifier for a resource, used to access it in the cache.
func NewObjectKey ¶
NewObjectKey creates a new ObjectKey for the given namespace and name.
type SecretEventHandlerRegistration ¶
type SecretEventHandlerRegistration interface { cache.ResourceEventHandlerRegistration GetKey() ObjectKey GetHandler() cache.ResourceEventHandlerRegistration }
SecretEventHandlerRegistration is for registering and unregistering event handlers for secret monitoring.
type SecretMonitor ¶
type SecretMonitor interface { // AddSecretEventHandler adds a secret event handler to the monitor for a specific secret in the given namespace. // The handler will be notified of events related to the "specified" secret only. // The returned SecretEventHandlerRegistration can be used to later remove the handler. AddSecretEventHandler(ctx context.Context, namespace, secretName string, handler cache.ResourceEventHandler) (SecretEventHandlerRegistration, error) // RemoveSecretEventHandler removes a previously added secret event handler using the provided registration. // If the handler is not found or if there is an issue removing it, an error is returned. RemoveSecretEventHandler(SecretEventHandlerRegistration) error // GetSecret retrieves the secret object from the informer's cache using the provided SecretEventHandlerRegistration. // This allows accessing the latest state of the secret without making an API call. GetSecret(SecretEventHandlerRegistration) (*v1.Secret, error) }
SecretMonitor helps in monitoring and handling a specific secret using singleItemMonitor.
func NewSecretMonitor ¶
func NewSecretMonitor(kubeClient kubernetes.Interface) SecretMonitor
Click to show internal directories.
Click to hide internal directories.