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

distsql: Unify endian for Chunk encode format #13349

Merged
merged 18 commits into from Nov 27, 2019
Merged

Conversation

@wshwsh12
Copy link
Contributor

wshwsh12 commented Nov 11, 2019

What problem does this PR solve?

When using chunk encode format for response , maybe the endian is different in tidb and tikv, and tidb can't decode the data.

What is changed and how it works?

Unify endian for Chunk encode format.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)

Code changes

Side effects

  • Increased code complexity

Related changes

Release note

wshwsh12 added 4 commits Nov 11, 2019
Signed-off-by: wshwsh12 <793703860@qq.com>
Signed-off-by: wshwsh12 <793703860@qq.com>
Signed-off-by: wshwsh12 <793703860@qq.com>
Signed-off-by: wshwsh12 <793703860@qq.com>
@qrr1995

This comment has been minimized.

Copy link
Contributor

qrr1995 commented Nov 11, 2019

/build

@codecov

This comment has been minimized.

Copy link

codecov bot commented Nov 12, 2019

Codecov Report

Merging #13349 into master will not change coverage.
The diff coverage is n/a.

@@             Coverage Diff             @@
##             master     #13349   +/-   ##
===========================================
  Coverage   80.1863%   80.1863%           
===========================================
  Files           474        474           
  Lines        116753     116753           
===========================================
  Hits          93620      93620           
  Misses        15761      15761           
  Partials       7372       7372
@wshwsh12 wshwsh12 added status/DNM and removed status/WIP labels Nov 12, 2019
@wshwsh12

This comment has been minimized.

Copy link
Contributor Author

wshwsh12 commented Nov 12, 2019

/run-all-tests

wshwsh12 added 3 commits Nov 12, 2019
@wshwsh12 wshwsh12 removed the status/DNM label Nov 14, 2019
@wshwsh12 wshwsh12 requested review from SunRunAway and XuHuaiyu Nov 24, 2019
@@ -169,5 +170,35 @@ func canUseChunkRPC(ctx sessionctx.Context) bool {
if ctx.GetSessionVars().EnableStreaming {
return false
}
if !supportedAlignment() {

This comment has been minimized.

Copy link
@SunRunAway

SunRunAway Nov 25, 2019

Member

We may check this when process starting and cache the result, instead of checking in each session.


// SetSystemEndian sets the system endian for the DAGRequest.
func SetSystemEndian(dagReq *tipb.DAGRequest) {
dagReq.TidbSystemEndian = GetSystemEndian()

This comment has been minimized.

Copy link
@SunRunAway

SunRunAway Nov 25, 2019

Member

We may check this when process starting and cache the result, instead of checking in each session.

distsql/request_builder_test.go Outdated Show resolved Hide resolved
distsql/distsql.go Outdated Show resolved Hide resolved
@wshwsh12 wshwsh12 requested a review from SunRunAway Nov 26, 2019
distsql/distsql.go Outdated Show resolved Hide resolved
distsql/distsql.go Outdated Show resolved Hide resolved
distsql/distsql.go Outdated Show resolved Hide resolved
@SunRunAway

This comment has been minimized.

Copy link
Member

SunRunAway commented Nov 26, 2019

And PTAL at the CI failure.

@wshwsh12

This comment has been minimized.

Copy link
Contributor Author

wshwsh12 commented Nov 26, 2019

And PTAL at the CI failure.

The CI fail is because tipb hasn't been merged to master and update.

Copy link
Member

SunRunAway left a comment

LGTM

@SunRunAway SunRunAway changed the title *: Unify endian for Chunk encode format distsql: Unify endian for Chunk encode format Nov 26, 2019
@wshwsh12 wshwsh12 requested a review from XuHuaiyu Nov 26, 2019
Copy link
Contributor

XuHuaiyu left a comment

LGTM

@wshwsh12 wshwsh12 added the status/DNM label Nov 26, 2019
wshwsh12 added 2 commits Nov 27, 2019
@sre-bot

This comment has been minimized.

Copy link

sre-bot commented Nov 27, 2019

/run-all-tests

@sre-bot sre-bot merged commit 134b80c into pingcap:master Nov 27, 2019
14 checks passed
14 checks passed
idc-jenkins-ci-tidb/build Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/build_check_race Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/check_dev Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/check_dev_2 Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/common-test job succeeded
Details
idc-jenkins-ci-tidb/integration-common-test Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/integration-compatibility-test Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/integration-copr-test Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/integration-ddl-test Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/mybatis-test job succeeded
Details
idc-jenkins-ci-tidb/sqllogic-test-1 Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/sqllogic-test-2 Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/unit-test Jenkins job succeeded.
Details
license/cla Contributor License Agreement is signed.
Details
SunRunAway added a commit to SunRunAway/tidb that referenced this pull request Dec 2, 2019
edytagarbarz added a commit to edytagarbarz/tidb that referenced this pull request Dec 5, 2019
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.