Skip to content

Commit

Permalink
Merge pull request #138684 from cockroachdb/blathers/backport-release…
Browse files Browse the repository at this point in the history
…-24.1-138088

release-24.1: ccl/multiregionccl: deflake TestRegionLivenessProberForLeases
  • Loading branch information
rafiss authored Jan 13, 2025
2 parents a874293 + bf4eb4b commit 8747c40
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/ccl/multiregionccl/regionliveness_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,9 @@ func TestRegionLivenessProberForLeases(t *testing.T) {
keyToBlockMu.Lock()
keyPrefix := keyToBlock
keyToBlockMu.Unlock()
if keyPrefix == nil || !deleteRequest.Key[:len(keyPrefix)].Equal(keyPrefix) {
isPrefixToDelReq := len(deleteRequest.Key) >= len(keyPrefix) &&
!deleteRequest.Key[:len(keyPrefix)].Equal(keyPrefix)
if keyPrefix == nil || isPrefixToDelReq {
return nil
}
recoveryStart <- struct{}{}
Expand Down

0 comments on commit 8747c40

Please sign in to comment.