Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DirectorClient ¶
type DirectorClient interface { typesbroker.ApplicationLister UpdateOperation(ctx context.Context, request *director.Request) error }
DirectorClient defines a Director client which is capable of fetching an application and notifying Director for operation state changes
type KubernetesClient ¶
type KubernetesClient interface { Get(ctx context.Context, key client.ObjectKey) (*v1alpha1.Operation, error) Delete(ctx context.Context, obj client.Object, opts ...client.DeleteOption) error }
KubernetesClient is a defines a Kubernetes client capable of retrieving and deleting resources as well as updating their status
type OperationReconciler ¶
type OperationReconciler struct {
// contains filtered or unexported fields
}
OperationReconciler reconciles an Operation object
func NewOperationReconciler ¶
func NewOperationReconciler(config *webhook.Config, statusManager StatusManager, k8sClient KubernetesClient, directorClient DirectorClient, webhookClient WebhookClient, collector *metrics.Collector) *OperationReconciler
func (*OperationReconciler) Reconcile ¶
Reconcile contains the Operations Controller logic concerned with processing and executing webhooks based on Operation CRs
func (*OperationReconciler) SetupWithManager ¶
func (r *OperationReconciler) SetupWithManager(mgr ctrl.Manager) error
type StatusManager ¶
type StatusManager interface { Initialize(ctx context.Context, operation *v1alpha1.Operation) error InProgressWithPollURL(ctx context.Context, operation *v1alpha1.Operation, pollURL string) error InProgressWithPollURLAndLastPollTimestamp(ctx context.Context, operation *v1alpha1.Operation, pollURL, lastPollTimestamp string, retryCount int) error SuccessStatus(ctx context.Context, operation *v1alpha1.Operation) error FailedStatus(ctx context.Context, operation *v1alpha1.Operation, errorMsg string) error }
StatusManager defines an abstraction for managing the status of a given kubernetes resource
type WebhookClient ¶
type WebhookClient interface { Do(ctx context.Context, request webhookclient.WebhookRequest) (*webhookdir.Response, error) Poll(ctx context.Context, request *webhookclient.PollRequest) (*webhookdir.ResponseStatus, error) }
WebhookClient defines a general purpose Webhook executor client
Click to show internal directories.
Click to hide internal directories.