Skip to content

Conversation

@ti-srebot
Copy link
Collaborator

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

cherry-pick #496 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/498

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

git push git@github.com:ti-srebot/client-java.git pr/498:release-3.1-6a6967a36260

Signed-off-by: marsishandsome marsishandsome@gmail.com

What problem does this PR solve?

close #497

Problem Description: Request timeout when receiving NOT_LEADER error the first time.

What is changed and how it works?

The reason is that error.toString will trigger JVM ClassLoader load grpc error related classes, which costs more than 100ms.

Solution: let JVM JVM ClassLoader load grpc error related classes during warmup.

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

/run-all-tests

Signed-off-by: marsishandsome <marsishandsome@gmail.com>
Copy link
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
Copy link
Collaborator

/run-all-tests

@marsishandsome marsishandsome merged commit 81a6efd into tikv:release-3.1 Jan 25, 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.

2 participants