Documentation
¶
Index ¶
- Constants
- Variables
- type OpenStackLoadBalancerReconciler
- type ResourceCleanupHandler
- func (h *ResourceCleanupHandler) CleanupResourcesForService(ctx context.Context, svc *corev1.Service) (bool, error)
- func (h *ResourceCleanupHandler) CleanupResourcesForServiceWithForce(ctx context.Context, svc *corev1.Service) (bool, error)
- func (h *ResourceCleanupHandler) HandleServiceFinalization(ctx context.Context, svc *corev1.Service) (bool, error)
- func (h *ResourceCleanupHandler) HandleServiceFinalizationWithForce(ctx context.Context, svc *corev1.Service) (bool, error)
Constants ¶
View Source
const ( // Condition types ConditionTypeReady = "Ready" ConditionTypeNetworkDetected = "NetworkDetected" ConditionTypePortCreated = "PortCreated" ConditionTypeFloatingIPCreated = "FloatingIPCreated" // Finalizer OpenstackLBFinalizer = "openstack.jacero.io/finalizer" ServiceFinalizer = "openstack.jacero.io/service-finalizer" // Annotations and labels AnnotationLoadBalancerClass = "service.kubernetes.io/loadbalancer-class" AnnotationPortID = "openstack.jacero.io/port-id" AnnotationFloatingIPID = "openstack.jacero.io/floating-ip-id" AnnotationCredentialsSecretName = "openstack.jacero.io/credentials-secret-name" AnnotationCredentialsSecretNamespace = "openstack.jacero.io/credentials-secret-namespace" LabelManagedBy = "app.kubernetes.io/managed-by" LabelCreatedFor = "openstack.jacero.io/created-for" )
View Source
const RequeueAfter = 30 * time.Second
RequeueAfter defines how long to wait before requeuing
Variables ¶
View Source
var ( RetryBackoff = wait.Backoff{ Steps: 5, Duration: 100 * time.Millisecond, Factor: 2.0, Jitter: 0.1, } )
Retry settings
Functions ¶
This section is empty.
Types ¶
type OpenStackLoadBalancerReconciler ¶
type OpenStackLoadBalancerReconciler struct { client.Client Scheme *runtime.Scheme Recorder record.EventRecorder }
OpenStackLoadBalancerReconciler reconciles a OpenStackLoadBalancer object
func (*OpenStackLoadBalancerReconciler) Reconcile ¶
func (r *OpenStackLoadBalancerReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
Reconcile handles the reconciliation loop for OpenStackLoadBalancer resources
func (*OpenStackLoadBalancerReconciler) SetupWithManager ¶
func (r *OpenStackLoadBalancerReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.
type ResourceCleanupHandler ¶
ResourceCleanupHandler handles the cleanup of OpenStack resources
func NewResourceCleanupHandler ¶
func NewResourceCleanupHandler(k8sClient client.Client, osClient openstack.Client) *ResourceCleanupHandler
NewResourceCleanupHandler creates a new instance of ResourceCleanupHandler
func (*ResourceCleanupHandler) CleanupResourcesForService ¶
func (h *ResourceCleanupHandler) CleanupResourcesForService(ctx context.Context, svc *corev1.Service) (bool, error)
CleanupResourcesForService cleans up all OpenStack resources associated with a service
func (*ResourceCleanupHandler) CleanupResourcesForServiceWithForce ¶ added in v0.2.0
func (h *ResourceCleanupHandler) CleanupResourcesForServiceWithForce(ctx context.Context, svc *corev1.Service) (bool, error)
CleanupResourcesForServiceWithForce cleans up resources more aggressively
func (*ResourceCleanupHandler) HandleServiceFinalization ¶
func (h *ResourceCleanupHandler) HandleServiceFinalization(ctx context.Context, svc *corev1.Service) (bool, error)
HandleServiceFinalization handles the finalization of a service that is being deleted
func (*ResourceCleanupHandler) HandleServiceFinalizationWithForce ¶ added in v0.2.0
Click to show internal directories.
Click to hide internal directories.