Documentation
¶
Index ¶
- Variables
- func ExcludeNamesFilter(names ...string) factory.EventFilterFunc
- func HandleManagementState(ctx context.Context, c consoleOperatorController, ...) error
- func IncludeNamesFilter(names ...string) factory.EventFilterFunc
- func IsExternalControlPlaneWithIngressDisabled(infrastructureConfig *configv1.Infrastructure, ...) bool
- func IsRetryableError(err error) bool
- func LabelFilter(labels map[string]string) factory.EventFilterFunc
- func RetryOnTransientError(fn func() error) error
- type InformerWithSwitch
Constants ¶
This section is empty.
Variables ¶
var TransientBackoff = wait.Backoff{ Steps: 3, Duration: 500 * time.Millisecond, Factor: 2.0, Jitter: 0.1, }
TransientBackoff defines the retry parameters for transient API errors. 3 steps with 500ms base and 2.0 factor gives: 500ms, 1s, 2s = ~3.5s max per call.
Functions ¶
func ExcludeNamesFilter ¶
func ExcludeNamesFilter(names ...string) factory.EventFilterFunc
Inverse of IncludeNamesFilter
func HandleManagementState ¶
func HandleManagementState(ctx context.Context, c consoleOperatorController, operatorClient v1helpers.OperatorClient) error
func IncludeNamesFilter ¶
func IncludeNamesFilter(names ...string) factory.EventFilterFunc
Return func which returns true if obj name is in names
func IsExternalControlPlaneWithIngressDisabled ¶
func IsExternalControlPlaneWithIngressDisabled(infrastructureConfig *configv1.Infrastructure, clusterVersionConfig *configv1.ClusterVersion) bool
IsExternalControlPlaneWithIngressDisabled returns true if the cluster is in external control plane topology (hypershift) and the ingress cluster capability is disabled.
func IsRetryableError ¶
IsRetryableError returns true for errors worth retrying — everything except known permanent errors. This naturally handles both API status errors (apierrors.StatusError) and network-level errors (connection refused, EOF, TLS failures) without explicit net.Error detection.
func LabelFilter ¶
func LabelFilter(labels map[string]string) factory.EventFilterFunc
Return a func which returns true if obj matches on every label in labels (i.e for each key in labels map, obj.metadata.labels[key] is equal to labels[key])
func RetryOnTransientError ¶
RetryOnTransientError wraps a function call with retry logic to absorb transient API server errors (conflicts, timeouts, connection refused) that occur during upgrades. Only API write operations (Apply, Create, Update, Delete) should be wrapped — not lister/cache reads.
Types ¶
type InformerWithSwitch ¶
type InformerWithSwitch struct {
// contains filtered or unexported fields
}
func NewSwitchedInformer ¶
func NewSwitchedInformer( ctx context.Context, oauthClient authclient.Interface, resync time.Duration, authnInformer configv1informers.AuthenticationInformer, recorder events.Recorder, ) *InformerWithSwitch
func (*InformerWithSwitch) Informer ¶
func (s *InformerWithSwitch) Informer() cache.SharedIndexInformer
func (*InformerWithSwitch) Lister ¶
func (s *InformerWithSwitch) Lister() oauthlistersv1.OAuthClientLister
func (*InformerWithSwitch) Start ¶
func (s *InformerWithSwitch) Start(stopCh <-chan struct{})