Skip to content

storage: deflake TestSnapshotAfterTruncationWithUncommittedTail#37105

Merged
craig[bot] merged 2 commits intocockroachdb:masterfrom
nvb:nvanbenschoten/fixNLEInRaftTest
Apr 25, 2019
Merged

storage: deflake TestSnapshotAfterTruncationWithUncommittedTail#37105
craig[bot] merged 2 commits intocockroachdb:masterfrom
nvb:nvanbenschoten/fixNLEInRaftTest

Conversation

@nvb
Copy link
Copy Markdown
Contributor

@nvb nvb commented Apr 24, 2019

Fixes #37085.

This PR fixes two flakes in TestSnapshotAfterTruncationWithUncommittedTail. The first has to do with unexpected NotLeaseHolderErrors and the second has to do with a stall that was possible due to incorrect filtering of MsgApps.

nvb added 2 commits April 24, 2019 17:15
…ithUncommittedTail

This avoids unnecessary NotLeaseHolderErrors when we don't need to enforce
which replica can evaluate a request. We see that in the current CI failure
in cockroachdb#37093.

Release note: None
Fixes cockroachdb#37085.

This filtering was assuming that the Raft message's index field
indicated the first index in the MsgApp. It actually indicates the
log index that _precedes_ any of the entries in the MsgApp.

It stole this from TestReplicaRangefeedRetryErrors, so the commit
updates that too.

Release note: None
@nvb nvb requested review from a team and ajwerner April 24, 2019 23:38
@cockroach-teamcity
Copy link
Copy Markdown
Member

This change is Reviewable

Copy link
Copy Markdown
Contributor

@ajwerner ajwerner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice find

Reviewed 1 of 1 files at r1, 2 of 2 files at r2.
Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained

@nvb
Copy link
Copy Markdown
Contributor Author

nvb commented Apr 25, 2019

bors r+

craig bot pushed a commit that referenced this pull request Apr 25, 2019
37105: storage: deflake TestSnapshotAfterTruncationWithUncommittedTail r=nvanbenschoten a=nvanbenschoten

Fixes #37085.

This PR fixes two flakes in TestSnapshotAfterTruncationWithUncommittedTail. The first has to do with unexpected NotLeaseHolderErrors and the second has to do with a stall that was possible due to incorrect filtering of `MsgApp`s.

Co-authored-by: Nathan VanBenschoten <nvanbenschoten@gmail.com>
@craig
Copy link
Copy Markdown
Contributor

craig bot commented Apr 25, 2019

Build succeeded

@craig craig bot merged commit 7e6906a into cockroachdb:master Apr 25, 2019
@nvb nvb deleted the nvanbenschoten/fixNLEInRaftTest branch May 2, 2019 17:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

teamcity: failed test: TestSnapshotAfterTruncationWithUncommittedTail

3 participants