Documentation ¶
Index ¶
- func GetConfigOrDieWithQPSAndBurst(qps float32, burst int) *rest.Config
- func NewCacheClientBypassSecrets(config *rest.Config, options client.Options) (client.Client, error)
- func NewFluidControllerClient(config *rest.Config, options client.Options) (client.Client, error)
- func NewFluidControllerRateLimiter(ItemExponentialFailureBaseDelay time.Duration, ...) ratelimiter.RateLimiter
- type OperationReconciler
- func (o *OperationReconciler) GetOrCreateEngine(ctx dataoperation.ReconcileRequestContext) (engine base.Engine, err error)
- func (o *OperationReconciler) ReconcileDeletion(ctx dataoperation.ReconcileRequestContext, ...) (ctrl.Result, error)
- func (o *OperationReconciler) ReconcileInternal(ctx dataoperation.ReconcileRequestContext) (ctrl.Result, error)
- func (o *OperationReconciler) RemoveEngine(namespacedName types.NamespacedName)
- type RuntimeReconciler
- func (r *RuntimeReconciler) AddFinalizerAndRequeue(ctx cruntime.ReconcileRequestContext, finalizerName string) (ctrl.Result, error)
- func (r *RuntimeReconciler) AddOwnerAndRequeue(ctx cruntime.ReconcileRequestContext, dataset *datav1alpha1.Dataset) (ctrl.Result, error)
- func (r *RuntimeReconciler) CheckIfReferenceDatasetIsSupported(ctx cruntime.ReconcileRequestContext) (bool, string)
- func (r *RuntimeReconciler) ForgetMetrics(ctx cruntime.ReconcileRequestContext)
- func (r *RuntimeReconciler) GetDataset(ctx cruntime.ReconcileRequestContext) (*datav1alpha1.Dataset, error)
- func (r *RuntimeReconciler) GetRuntimeObjectMeta(ctx cruntime.ReconcileRequestContext) (objectMeta metav1.Object, err error)
- func (r *RuntimeReconciler) ReconcileInternal(ctx cruntime.ReconcileRequestContext) (ctrl.Result, error)
- func (r *RuntimeReconciler) ReconcileRuntime(engine base.Engine, ctx cruntime.ReconcileRequestContext) (result ctrl.Result, err error)
- func (r *RuntimeReconciler) ReconcileRuntimeDeletion(engine base.Engine, ctx cruntime.ReconcileRequestContext) (ctrl.Result, error)
- func (r *RuntimeReconciler) ReportDatasetNotReadyCondition(ctx cruntime.ReconcileRequestContext, notReadyReason error) error
- type RuntimeReconcilerInterface
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetConfigOrDieWithQPSAndBurst ¶ added in v1.0.0
GetConfigOrDieWithQPSAndBurst sets client-side QPS and burst in kube config.
func NewCacheClientBypassSecrets ¶ added in v1.0.0
func NewCacheClientBypassSecrets(config *rest.Config, options client.Options) (client.Client, error)
NewCacheClientBypassSecrets creates a client querying kubernetes resources with cache(informers) except for Secrets. Secret is an exception for that we aim to trade performance for higher security(e.g. less rbac verbs on Secrets).
func NewFluidControllerClient ¶ added in v1.0.0
NewFluidControllerClient creates client.Client according to the HELM_DRIVER env variable. It returns the default client when setting HELM_DRIVER=true, meaning users explicitly grant secret permissions to Fluid controllers. Otherwise, it returns a specific client.Client that utilizes informers as cache except for Secrets.
func NewFluidControllerRateLimiter ¶ added in v1.0.0
func NewFluidControllerRateLimiter( ItemExponentialFailureBaseDelay time.Duration, ItemExponentialFailureMaxDelay time.Duration, overallBucketQPS int, overallBucketBurst int) ratelimiter.RateLimiter
NewFluidControllerRateLimiter inherits the default controller rate limiter in workqueue.DefaultControllerRateLimiter() but with configurable parameters passed to the underlying rate limiters.
Types ¶
type OperationReconciler ¶ added in v0.9.0
type OperationReconciler struct { client.Client Log logr.Logger Recorder record.EventRecorder // contains filtered or unexported fields }
OperationReconciler is the default implementation
func NewDataOperationReconciler ¶ added in v0.9.0
func NewDataOperationReconciler(operationReconcilerInterface dataoperation.OperationInterfaceBuilder, client client.Client, log logr.Logger, recorder record.EventRecorder) *OperationReconciler
NewDataOperationReconciler creates the default OperationReconciler
func (*OperationReconciler) GetOrCreateEngine ¶ added in v0.9.0
func (o *OperationReconciler) GetOrCreateEngine( ctx dataoperation.ReconcileRequestContext) (engine base.Engine, err error)
GetOrCreateEngine gets the Engine require each runtime must use ddc.CreateEngine to create engine
func (*OperationReconciler) ReconcileDeletion ¶ added in v0.9.0
func (o *OperationReconciler) ReconcileDeletion(ctx dataoperation.ReconcileRequestContext, implement dataoperation.OperationInterface) (ctrl.Result, error)
ReconcileDeletion reconciles the deletion of the DataBackup
func (*OperationReconciler) ReconcileInternal ¶ added in v0.9.0
func (o *OperationReconciler) ReconcileInternal(ctx dataoperation.ReconcileRequestContext) (ctrl.Result, error)
func (*OperationReconciler) RemoveEngine ¶ added in v0.9.0
func (o *OperationReconciler) RemoveEngine(namespacedName types.NamespacedName)
type RuntimeReconciler ¶
type RuntimeReconciler struct { client.Client Log logr.Logger Recorder record.EventRecorder // contains filtered or unexported fields }
RuntimeReconciler is the default implementation
func NewRuntimeReconciler ¶
func NewRuntimeReconciler(reconciler RuntimeReconcilerInterface, client client.Client, log logr.Logger, recorder record.EventRecorder) *RuntimeReconciler
NewRuntimeReconciler creates the default RuntimeReconciler
func (*RuntimeReconciler) AddFinalizerAndRequeue ¶
func (r *RuntimeReconciler) AddFinalizerAndRequeue(ctx cruntime.ReconcileRequestContext, finalizerName string) (ctrl.Result, error)
AddFinalizerAndRequeue add finalizer and requeue
func (*RuntimeReconciler) AddOwnerAndRequeue ¶ added in v0.5.0
func (r *RuntimeReconciler) AddOwnerAndRequeue(ctx cruntime.ReconcileRequestContext, dataset *datav1alpha1.Dataset) (ctrl.Result, error)
AddOwnerAndRequeue add Owner and requeue
func (*RuntimeReconciler) CheckIfReferenceDatasetIsSupported ¶ added in v0.9.0
func (r *RuntimeReconciler) CheckIfReferenceDatasetIsSupported(ctx cruntime.ReconcileRequestContext) (bool, string)
func (*RuntimeReconciler) ForgetMetrics ¶ added in v0.9.0
func (r *RuntimeReconciler) ForgetMetrics(ctx cruntime.ReconcileRequestContext)
ForgetMetrics deletes related metrics in prometheus metrics to avoid memory inflation
func (*RuntimeReconciler) GetDataset ¶
func (r *RuntimeReconciler) GetDataset(ctx cruntime.ReconcileRequestContext) (*datav1alpha1.Dataset, error)
GetDataset gets the dataset
func (*RuntimeReconciler) GetRuntimeObjectMeta ¶
func (r *RuntimeReconciler) GetRuntimeObjectMeta(ctx cruntime.ReconcileRequestContext) (objectMeta metav1.Object, err error)
GetRuntimeObjectMeta gets runtime object meta
func (*RuntimeReconciler) ReconcileInternal ¶
func (r *RuntimeReconciler) ReconcileInternal(ctx cruntime.ReconcileRequestContext) (ctrl.Result, error)
ReconcileInternal handles the logic of reconcile runtime
func (*RuntimeReconciler) ReconcileRuntime ¶
func (r *RuntimeReconciler) ReconcileRuntime(engine base.Engine, ctx cruntime.ReconcileRequestContext) (result ctrl.Result, err error)
ReconcileRuntime reconciles runtime
func (*RuntimeReconciler) ReconcileRuntimeDeletion ¶
func (r *RuntimeReconciler) ReconcileRuntimeDeletion(engine base.Engine, ctx cruntime.ReconcileRequestContext) (ctrl.Result, error)
ReconcileRuntimeDeletion reconciles runtime deletion
func (*RuntimeReconciler) ReportDatasetNotReadyCondition ¶ added in v0.9.0
func (r *RuntimeReconciler) ReportDatasetNotReadyCondition(ctx cruntime.ReconcileRequestContext, notReadyReason error) error
type RuntimeReconcilerInterface ¶
type RuntimeReconcilerInterface interface { // ReconcileRuntimeDeletion reconcile runtime deletion ReconcileRuntimeDeletion(engine base.Engine, ctx cruntime.ReconcileRequestContext) (ctrl.Result, error) // ReconcileRuntime reconciles runtime ReconcileRuntime(engine base.Engine, ctx cruntime.ReconcileRequestContext) (ctrl.Result, error) // AddFinalizerAndRequeue add finalizer and requeue AddFinalizerAndRequeue(ctx cruntime.ReconcileRequestContext, finalizerName string) (ctrl.Result, error) // GetDataset gets the dataset GetDataset(ctx cruntime.ReconcileRequestContext) (*datav1alpha1.Dataset, error) // GetOrCreateEngine gets or creates engine GetOrCreateEngine( ctx cruntime.ReconcileRequestContext) (engine base.Engine, err error) // RemoveEngine removes engine RemoveEngine(ctx cruntime.ReconcileRequestContext) // GetRuntimeObjectMeta get runtime objectmeta GetRuntimeObjectMeta(ctx cruntime.ReconcileRequestContext) (metav1.Object, error) // ReconcileInternal ReconcileInternal(ctx cruntime.ReconcileRequestContext) (ctrl.Result, error) }
The interface of RuntimeReconciler