Skip to content

Commit

Permalink
Merge #25642
Browse files Browse the repository at this point in the history
25642: storage: bump RaftTickInterval in TestReplicaLazyLoad r=nvanbenschoten a=nvanbenschoten

Fixes #25430.

Before this change, the `RaftTickInterval` in the test was so low that
node liveness only had a few milliseconds to perform updates. This
caused the test to be flaky, especially in #25281, which is slowing
down all tests by changing from in-memory stores to on-disk stores. By
bumping up the `RaftTickInterval` by an order of magnitude in the test,
we give node liveness much more time to perform updates.

Release note: None

Co-authored-by: Nathan VanBenschoten <nvanbenschoten@gmail.com>
  • Loading branch information
craig[bot] and nvanbenschoten committed May 18, 2018
2 parents 6ec028d + 327a45d commit 381eb8d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/storage/client_raft_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3094,7 +3094,7 @@ func TestReplicaLazyLoad(t *testing.T) {
defer leaktest.AfterTest(t)()

sc := storage.TestStoreConfig(nil)
sc.RaftTickInterval = time.Millisecond // safe because there is only a single node
sc.RaftTickInterval = 10 * time.Millisecond // safe because there is only a single node
sc.TestingKnobs.DisableScanner = true
sc.TestingKnobs.DisablePeriodicGossips = true
mtc := &multiTestContext{storeConfig: &sc}
Expand Down

0 comments on commit 381eb8d

Please sign in to comment.