Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

raftstore: fix duplicate `ctx` of read index #5213

Merged
merged 9 commits into from Aug 12, 2019

Conversation

@5kbpers
Copy link
Contributor

5kbpers commented Aug 6, 2019

Signed-off-by: 5kbpers tangminghua@pingcap.com

What have you changed? (mandatory)

The ctx of pending reading is independently produced by tikv itself, it may same in leader and follower at the same time, the ReadIndex request will conflict and may lose one.
This PR changes the ctx to UUID instead of a monotonic number.

What are the type of the changes? (mandatory)

  • Bug fix (change which fixes an issue)

How has this PR been tested? (mandatory)

CI

Does this PR affect documentation (docs) or release note? (mandatory)

No

Does this PR affect tidb-ansible update? (mandatory)

No

Refer to a related PR or issue link (optional)

#4764

Signed-off-by: 5kbpers <tangminghua@pingcap.com>
@5kbpers

This comment has been minimized.

Copy link
Contributor Author

5kbpers commented Aug 6, 2019

/run-all-tests

Copy link
Contributor

overvenus left a comment

Could you a test?

src/raftstore/store/peer.rs Outdated Show resolved Hide resolved
src/raftstore/store/peer.rs Outdated Show resolved Hide resolved
5kbpers added 2 commits Aug 6, 2019
Signed-off-by: 5kbpers <tangminghua@pingcap.com>
Signed-off-by: 5kbpers <tangminghua@pingcap.com>
@5kbpers 5kbpers requested a review from overvenus Aug 7, 2019
@5kbpers 5kbpers force-pushed the 5kbpers:duplicate-read-index-ctx branch from ae1a463 to 144f1b5 Aug 7, 2019
use UUID
Signed-off-by: 5kbpers <tangminghua@pingcap.com>
@5kbpers 5kbpers force-pushed the 5kbpers:duplicate-read-index-ctx branch from 144f1b5 to b046f25 Aug 7, 2019
@5kbpers 5kbpers requested a review from BusyJay Aug 7, 2019
@nolouch
nolouch approved these changes Aug 8, 2019
Copy link
Contributor

nolouch left a comment

LGTM

@5kbpers

This comment has been minimized.

Copy link
Contributor Author

5kbpers commented Aug 9, 2019

/run-all-tests

1 similar comment
@5kbpers

This comment has been minimized.

Copy link
Contributor Author

5kbpers commented Aug 9, 2019

/run-all-tests

5kbpers and others added 2 commits Aug 9, 2019
@nolouch

This comment has been minimized.

Copy link
Contributor

nolouch commented Aug 12, 2019

/release

@overvenus

This comment has been minimized.

Copy link
Contributor

overvenus commented Aug 12, 2019

/run-integration-tests

@sre-bot

This comment has been minimized.

Copy link
Collaborator

sre-bot commented Aug 12, 2019

/run-all-tests

@sre-bot sre-bot merged commit f83c09c into tikv:master Aug 12, 2019
5 checks passed
5 checks passed
DCO All commits are signed off!
Details
idc-jenkins-ci-tikv/integration-common-test Jenkins job succeeded.
Details
idc-jenkins-ci-tikv/integration-compatibility-test Jenkins job succeeded.
Details
idc-jenkins-ci-tikv/integration-ddl-test Jenkins job succeeded.
Details
idc-jenkins-ci/test Jenkins job succeeded.
Details
@sre-bot

This comment has been minimized.

Copy link
Collaborator

sre-bot commented Aug 12, 2019

cherry pick to release-3.0 failed

YangKeao added a commit to YangKeao/tikv that referenced this pull request Aug 26, 2019
Signed-off-by: 5kbpers <tangminghua@pingcap.com>
YangKeao added a commit to YangKeao/tikv that referenced this pull request Sep 5, 2019
sticnarf pushed a commit to sticnarf/tikv that referenced this pull request Oct 27, 2019
Signed-off-by: 5kbpers <tangminghua@pingcap.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants
You can’t perform that action at this time.