Skip to content

Commit

Permalink
Reduce the time waiting for the webhook (#422)
Browse files Browse the repository at this point in the history
  • Loading branch information
TerryHowe authored Aug 18, 2022
1 parent 8911ca2 commit 9963625
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions controllers/packagebundlecontroller_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ package controllers
import (
"context"
"fmt"
"strings"
"time"

"github.com/go-logr/logr"
Expand Down Expand Up @@ -125,6 +126,9 @@ func (r *PackageBundleControllerReconciler) Reconcile(ctx context.Context, req c
err = r.bundleManager.ProcessBundleController(ctx, pbc)
if err != nil {
r.Log.Error(err, "processing bundle controller")
if strings.Contains("Internal error occurred: failed calling webhook", err.Error()) {
result.RequeueAfter = time.Second * 2
}
return result, nil
}

Expand Down

0 comments on commit 9963625

Please sign in to comment.