Skip to content

Commit

Permalink
Speed up ring key ownership tests
Browse files Browse the repository at this point in the history
Signed-off-by: Nick Pillitteri <[email protected]>
  • Loading branch information
56quarters committed Jan 3, 2025
1 parent e17f2cc commit 6c1dec6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ring/token_range_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ func TestCheckingOfKeyOwnership(t *testing.T) {
}

func testCheckingOfKeyOwnership(t *testing.T, randomizeInstanceStates bool) {
const instancesPerZone = 100
const instancesPerZone = 20
const numZones = 3
const numTokens = 512
const replicationFactor = numZones // This is the only config supported by GetTokenRangesForInstance right now.
Expand All @@ -204,7 +204,7 @@ func testCheckingOfKeyOwnership(t *testing.T, randomizeInstanceStates bool) {
// Generate users with different number of tokens
userTokens := map[string][]uint32{}
shardSizes := map[string]int{}
for _, cnt := range []int{1000, 5000, 10000, 25000, 50000, 100000, 250000, 500000} {
for _, cnt := range []int{1000, 5000, 10000, 25000, 50000, 100000} {
uid := fmt.Sprintf("%dk", cnt/1000)
userTokens[uid] = gen.GenerateTokens(cnt, nil)

Expand Down

0 comments on commit 6c1dec6

Please sign in to comment.