Skip to content
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.

Commit

Permalink
skip envoyfilter deletion if not present already
Browse files Browse the repository at this point in the history
  • Loading branch information
rahulanand16nov committed Jun 8, 2022
1 parent 8e2aa18 commit 0260e9d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions controllers/apim/ratelimitpolicy_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,7 @@ func (r *RateLimitPolicyReconciler) cleanUpOrphanWASMPlugins(ctx context.Context
logger.V(1).Info("cleanUpOrphanWASMPlugins: get EnvoyFilter", "envoyfilter", efKey, "err", err)
if apierrors.IsNotFound(err) {
logger.Info("cleanUpOrphanWASMPlugins: envoyfilter not found", "envoyFilter", efKey)
continue
}
err = r.DeleteResource(ctx, ef)
if err != nil {
Expand Down
1 change: 1 addition & 0 deletions controllers/apim/ratelimitpolicy_finalizers.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ func (r *RateLimitPolicyReconciler) finalizeWASMPlugins(ctx context.Context, rlp
logger.V(1).Info("finalizeWASMPlugins: get EnvoyFilter", "envoyfilter", efKey, "err", err)
if apierrors.IsNotFound(err) {
logger.Info("finalizeWASMPlugins: envoyfilter not found", "envoyFilter", efKey)
continue
}
err = r.DeleteResource(ctx, ef)
if err != nil {
Expand Down

0 comments on commit 0260e9d

Please sign in to comment.