Skip to content

[close #489 ] fix backoffer data race (#490)#494

Merged
marsishandsome merged 2 commits intotikv:release-3.1from
ti-srebot:release-3.1-a7e0e74bd76c
Jan 21, 2022
Merged

[close #489 ] fix backoffer data race (#490)#494
marsishandsome merged 2 commits intotikv:release-3.1from
ti-srebot:release-3.1-a7e0e74bd76c

Conversation

@ti-srebot
Copy link
Copy Markdown
Collaborator

@ti-srebot ti-srebot commented Jan 21, 2022

cherry-pick #490 to release-3.1
You can switch your code base to this Pull Request by using git-extras:

# In client-java repo:
git pr https://github.com/tikv/client-java/pull/494

After apply modifications, you can push your change to this PR via:

git push git@github.com:ti-srebot/client-java.git pr/494:release-3.1-a7e0e74bd76c

Signed-off-by: iosmanthus myosmanthustree@gmail.com

What problem does this PR solve?

Issue Number: close #489

ConcreteBackOffer may trigger by multiple threads but the backOffFunctionMap is HashMap which is not thread-safe. This might trigger a race exception while this backoffer is shared between threads.

Signed-off-by: ti-srebot <ti-srebot@pingcap.com>
@ti-srebot
Copy link
Copy Markdown
Collaborator Author

/run-all-tests

Signed-off-by: iosmanthus <myosmanthustree@gmail.com>
Copy link
Copy Markdown
Member

@iosmanthus iosmanthus left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Copy Markdown
Member

@zz-jason zz-jason left a comment

Choose a reason for hiding this comment

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

LGTM

@iosmanthus
Copy link
Copy Markdown
Member

/merge

@ti-srebot
Copy link
Copy Markdown
Collaborator Author

/run-all-tests

@ti-srebot
Copy link
Copy Markdown
Collaborator Author

@ti-srebot merge failed.

Copy link
Copy Markdown
Collaborator

@marsishandsome marsishandsome left a comment

Choose a reason for hiding this comment

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

LGTM

@marsishandsome marsishandsome merged commit 5cd888b into tikv:release-3.1 Jan 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants