Skip to content

Commit

Permalink
reduce dataImage unmanagedRetryDelay to 10 seconds
Browse files Browse the repository at this point in the history
Signed-off-by: Himanshu Roy <hroy@redhat.com>
  • Loading branch information
hroyrh committed Nov 6, 2024
1 parent 2a379d7 commit c1a83e1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion controllers/metal3.io/baremetalhost_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -1593,7 +1593,7 @@ func (r *BareMetalHostReconciler) handleDataImageActions(prov provisioner.Provis
if hostDeleteTriggered {
detachReason = "BMH requested to be deleted"
}
info.log.Info("%w, requesting DataImage detach", "Reason", detachReason)
info.log.Info("Requesting DataImage detach", "Reason", detachReason)
if attachedURL != "" || dirty {
info.log.Info("Detaching DataImage, Reason = %w", "Reason", detachReason)
err := r.detachDataImage(prov, info, dataImage)
Expand Down
7 changes: 4 additions & 3 deletions controllers/metal3.io/dataimage_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,9 @@ import (
)

const (
dataImageRetryDelay = time.Second * 60
dataImageUpdateDelay = time.Second * 30
dataImageRetryDelay = time.Second * 60
dataImageUpdateDelay = time.Second * 30
dataImageUnmanagedRetryDelay = time.Second * 10
)

// DataImageReconciler reconciles a DataImage object.
Expand Down Expand Up @@ -129,7 +130,7 @@ func (r *DataImageReconciler) Reconcile(ctx context.Context, req ctrl.Request) (

if hasDetachedAnnotation(bmh) {
reqLogger.Info("the host is detached, not running reconciler")
return ctrl.Result{Requeue: true, RequeueAfter: unmanagedRetryDelay}, nil
return ctrl.Result{Requeue: true, RequeueAfter: dataImageUnmanagedRetryDelay}, nil
}

// If the reconciliation is paused, requeue
Expand Down

0 comments on commit c1a83e1

Please sign in to comment.