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

service: handle BatchCommandsEmptyRequest #5001

Merged
merged 5 commits into from Jul 3, 2019

Conversation

Projects
None yet
3 participants
@hicqu
Copy link
Contributor

commented Jul 2, 2019

Signed-off-by: qupeng qupeng@pingcap.com

What have you changed? (mandatory)

Handle BatchCommandsRequst::Empty. This message is generally for tests, make us can focus on transport layer instead of backend logics.

Relative works

  • I suggeste to cherry pick it to release-3.0, so that we can do more tests for release-3.0.
service: handle BatchCommandsEmptyRequest
Signed-off-by: qupeng <qupeng@pingcap.com>

@hicqu hicqu requested review from zhangjinpeng1987 and Connor1996 Jul 2, 2019

@Connor1996 Connor1996 added the C: Server label Jul 2, 2019

@overvenus
Copy link
Contributor

left a comment

Rest LGTM

let resp = future_handle_empty(req)
.map(oneof!(BatchCommandsResponse_Response_oneof_cmd::Empty))
.map_err(|_| GRPC_MSG_FAIL_COUNTER.invalid.inc());
response_batch_commands_request(id, resp, tx, timer);

This comment has been minimized.

Copy link
@overvenus

overvenus Jul 2, 2019

Contributor

Could you add a test?

This comment has been minimized.

Copy link
@hicqu

hicqu Jul 3, 2019

Author Contributor

There is already a test case in tests/integrations/server/kv_service.rs.

This comment has been minimized.

Copy link
@overvenus

overvenus Jul 3, 2019

Contributor

I mean the Empty request.

This comment has been minimized.

Copy link
@hicqu

hicqu Jul 3, 2019

Author Contributor

I think it's not necessary. Empty itself is simple enough.

hicqu added some commits Jul 3, 2019

@Connor1996
Copy link
Member

left a comment

LGTM

@hicqu hicqu merged commit 7ba293d into tikv:master Jul 3, 2019

2 checks passed

DCO All commits are signed off!
Details
idc-jenkins-ci/test Jenkins job succeeded.
Details

@hicqu hicqu deleted the hicqu:batch-commands-test branch Jul 3, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.