Skip to content

Commit

Permalink
kv: massage IsExpectedRebalanceError
Browse files Browse the repository at this point in the history
The error that would bubble up when a raft group got deleted has changed
slightly, likely as a result of #62719.

Fixes #65546.

Release note: None
  • Loading branch information
tbg committed May 25, 2021
1 parent 4ceda0b commit 34908fd
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/kv/test_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,13 @@ func IsExpectedRelocateError(err error) bool {
"unable to remove replica .* which is not present",
"unable to add replica .* which is already present",
"received invalid ChangeReplicasTrigger .* to remove self",
"failed to apply snapshot: raft group deleted",
"raft group deleted",
"snapshot failed",
"breaker open",
"unable to select removal target", // https://github.com/cockroachdb/cockroach/issues/49513
"cannot up-replicate to .*; missing gossiped StoreDescriptor",
"remote couldn't accept .* snapshot",
"cannot add placeholder",
}
pattern := "(" + strings.Join(allowlist, "|") + ")"
return testutils.IsError(err, pattern)
Expand Down

0 comments on commit 34908fd

Please sign in to comment.