Skip to content

Commit

Permalink
Merge pull request #4109 from zendesk/amir/karmada-sync-failed
Browse files Browse the repository at this point in the history
karmada: ignore sync failure errors since they are temporary
  • Loading branch information
a7i committed Mar 8, 2024
2 parents f184b60 + c5fae89 commit fd351f2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
3 changes: 2 additions & 1 deletion plugins/kubernetes/app/models/kubernetes/resource_status.rb
Expand Up @@ -29,7 +29,8 @@ class ResourceStatus
# karmada can fail to sync a resource when something else also updated the resource,
# this does not necessarily indicate that sync will be broken forever
All: [
'ApplyPolicyFailed'
'ApplyPolicyFailed',
'SyncFailed'
]
}.freeze

Expand Down
Expand Up @@ -111,10 +111,15 @@ def expect_event_request(&block)
expect_event_request { details.must_equal "Error event" }
end

it "ignores karmada sync" do
it "ignores karmada sync for policy failed" do
events[0][:reason] = "ApplyPolicyFailed"
expect_event_request { details.must_equal "Live" }
end

it "ignores karmada syn for sync failed" do
events[0][:reason] = "SyncFailed"
expect_event_request { details.must_equal "Live" }
end
end
end
end
Expand Down

0 comments on commit fd351f2

Please sign in to comment.