-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
*: encode the returned data using the Chunk format in mocktikv #12023
Conversation
ed527ae
to
4ed0984
Compare
Codecov Report
@@ Coverage Diff @@
## master #12023 +/- ##
================================================
- Coverage 79.9846% 79.8944% -0.0903%
================================================
Files 462 462
Lines 103171 103240 +69
================================================
- Hits 82521 82483 -38
- Misses 14758 14860 +102
- Partials 5892 5897 +5 |
/run-all-tests |
4ed0984
to
4e5a90f
Compare
/run-common-test |
b65cc2f
to
818f590
Compare
/run-all-tests tikv=pr/5461 |
/run-all-tests tikv=pr/5461 tidb-test=pr/898 |
distsql/distsql.go
Outdated
} | ||
} | ||
|
||
func useChunkIPC(ctx sessionctx.Context) bool { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/ useChunkIPC/ enableTypeArrow
return nil | ||
} | ||
|
||
func (h *rpcHandler) constructRespSchema(dagCtx *dagContext) []*types.FieldType { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this function also useless, dagCtx.evalCtx.fieldTps is enough?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -352,6 +352,9 @@ type SessionVars struct { | |||
// TODO: remove this after tidb-server configuration "enable-streaming' removed. | |||
EnableStreaming bool | |||
|
|||
// EnableArrow indicates whether the coprocessor request can use arrow API. | |||
EnableArrow bool |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can make this config item be able to be reloaded without restarting the tidb-server like other hot-reloadable config items. It's not urgent, we can do this in another PR.
/run-all-tests |
The enable-arrow needs to be set to false now.
/bench |
@@ Benchmark Diff @@
================================================================================
--- tidb: 5986c6cbfa9b2007e69cfe2a73bd094d984c5a21
+++ tidb: 388fed5c5652039a05e405cac875de579fb374a8
tikv: a036e28195aa23658e1de9a15e6f802cd1d927ea
pd: e2dbdf6ead101aeb1aa6d1298ecb3f1fc0ee62f1
================================================================================
test-1: < oltp_read_write >
* QPS : 37286.82 ± 0.2529% (std=58.48) delta: 0.34% (p=0.118)
* AvgMs : 137.86 ± 0.2481% (std=0.21) delta: -0.34%
* PercentileMs99 : 267.41 ± 0.0000% (std=0.00) delta: 0.00%
test-2: < oltp_point_select >
* QPS : 81169.01 ± 3.4426% (std=1613.65) delta: -1.09% (p=0.396)
* AvgMs : 3.15 ± 3.4264% (std=0.06) delta: 1.03%
* PercentileMs99 : 6.74 ± 2.8478% (std=0.12) delta: 0.36%
test-3: < oltp_insert >
* QPS : 21748.36 ± 0.2988% (std=43.00) delta: -0.48% (p=0.337)
* AvgMs : 11.77 ± 0.3229% (std=0.02) delta: 0.51%
* PercentileMs99 : 24.12 ± 1.0696% (std=0.21) delta: 1.45%
test-4: < oltp_update_index >
* QPS : 16999.35 ± 0.3929% (std=48.95) delta: -0.02% (p=0.240)
* AvgMs : 14.94 ± 0.7230% (std=0.07) delta: 0.17%
* PercentileMs99 : 30.81 ± 0.0000% (std=0.00) delta: 0.35%
test-5: < oltp_update_non_index >
* QPS : 29083.71 ± 0.0333% (std=7.54) delta: -0.25% (p=0.232)
* AvgMs : 8.79 ± 0.1422% (std=0.01) delta: 0.19%
* PercentileMs99 : 19.29 ± 0.0000% (std=0.00) delta: 0.00%
|
/run-all-tests |
/rebuild |
What problem does this PR solve?
Return chunk-encoded data when the requested
EncodeType
isTypeArrow
.What is changed and how it works?
Check List
Tests
Code changes
Side effects
BenchMark
Now I only test the time cost in TPCH-Q5. (10g data)
The reuslt: (Default concurrency)
The reuslt: (
set tidb_index_lookup_join_concurrency=16;
)Default
Arrow
The cpu time of
Decode
disappears.I will add more performance test and count the memory use.