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

*: support read tidb cluster memory table #13065

Merged
merged 81 commits into from
Dec 4, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
81 commits
Select commit Hold shift + click to select a range
4b1051b
hackathon init
crazycs520 Oct 26, 2019
cdd5115
add tikv info tables
crazycs520 Oct 26, 2019
4f8effb
add store info to tikv req
crazycs520 Oct 26, 2019
85e601e
check region id 0 before retry
crazycs520 Oct 26, 2019
c92dfd1
add tidb config table
crazycs520 Oct 26, 2019
2a66b64
update.
tangwz Oct 26, 2019
7303134
add network info, cpu/mem usage, stats
crazycs520 Oct 26, 2019
d252a0d
add cluster table for before tables
crazycs520 Oct 26, 2019
b8168a9
add tidb tables
crazycs520 Oct 26, 2019
55f6643
refinee table schema
crazycs520 Oct 26, 2019
ccd1754
add tikv schema, set tikv config
crazycs520 Oct 27, 2019
0682a22
fix statement bug
crazycs520 Oct 27, 2019
1d66b9d
try to make better
crazycs520 Oct 27, 2019
765f736
remove pd/tikv mem table code and add test
crazycs520 Oct 29, 2019
7a96f5b
remove set var and remove code
crazycs520 Oct 29, 2019
e7c8d61
remove code
crazycs520 Oct 29, 2019
973700f
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Oct 29, 2019
6fba533
remove add slow log field
crazycs520 Oct 29, 2019
545c1e9
clean code
crazycs520 Oct 30, 2019
76d7853
clean code
crazycs520 Oct 31, 2019
92ee6c5
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Oct 31, 2019
f530591
fix count(*) bug
crazycs520 Oct 31, 2019
b8971b9
fix test
crazycs520 Oct 31, 2019
6bf3107
refine code
crazycs520 Nov 1, 2019
5a22cb2
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Nov 1, 2019
2f824e7
rename cluster table name
crazycs520 Nov 1, 2019
73fbeb3
Merge branch 'master' into mpp
crazycs520 Nov 2, 2019
ae40d97
Merge branch 'master' into mpp
crazycs520 Nov 3, 2019
74bcf69
remove redundant code
crazycs520 Nov 6, 2019
5e12690
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Nov 11, 2019
ea3c431
refine code
crazycs520 Nov 11, 2019
d11c30c
Update domain/infosync/info.go
crazycs520 Nov 12, 2019
d832587
Update meta/meta.go
crazycs520 Nov 12, 2019
95db09e
address comment
crazycs520 Nov 12, 2019
c5791a5
Merge branch 'mpp' of https://github.com/crazycs520/tidb into mpp
crazycs520 Nov 12, 2019
0a78402
split pr code
crazycs520 Nov 13, 2019
484b20b
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Nov 13, 2019
c8f7b3d
fix go.mod
crazycs520 Nov 13, 2019
47d033e
Update infoschema/cluster.go
crazycs520 Nov 18, 2019
1aae4f8
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Nov 19, 2019
d2456cd
add error check
crazycs520 Nov 19, 2019
81d2065
remove generated tidb ID
crazycs520 Nov 19, 2019
7b9a738
Merge branch 'mpp' of https://github.com/crazycs520/tidb into mpp
crazycs520 Nov 19, 2019
71435fc
address comment
crazycs520 Nov 19, 2019
c7d79c9
rename file
crazycs520 Nov 19, 2019
8e022b5
Squashed commit of the following:
crazycs520 Nov 25, 2019
8c413a0
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Nov 26, 2019
5237273
add test
crazycs520 Nov 26, 2019
490df49
refine code
crazycs520 Nov 26, 2019
39831ff
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Nov 26, 2019
b37cc5d
refine code
crazycs520 Nov 26, 2019
d0939d1
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Nov 27, 2019
1339473
fix bug of register rpc server
crazycs520 Nov 27, 2019
eea0f56
add todo
crazycs520 Nov 27, 2019
c31d70d
refine code
crazycs520 Nov 27, 2019
a2727a0
address comment
crazycs520 Nov 27, 2019
abcb52b
address comment
crazycs520 Nov 27, 2019
08dc35d
address comment
crazycs520 Nov 27, 2019
9f3b17f
address comment
crazycs520 Nov 27, 2019
6b3550b
remove mem table scan
crazycs520 Nov 27, 2019
c627c0b
allocate the constan id for system schema/table
crazycs520 Nov 27, 2019
8da07d5
address comment
crazycs520 Nov 28, 2019
889fab3
Update store/tikv/client.go
crazycs520 Nov 28, 2019
43eae25
address comment
crazycs520 Nov 28, 2019
781b38b
Merge branch 'mpp' of https://github.com/crazycs520/tidb into mpp
crazycs520 Nov 29, 2019
8311509
Update executor/coprocessor.go
crazycs520 Nov 29, 2019
c8b856e
address comment
crazycs520 Nov 29, 2019
a5baf88
Merge branch 'mpp' of https://github.com/crazycs520/tidb into mpp
crazycs520 Nov 29, 2019
b4c0a8d
address comment
crazycs520 Dec 2, 2019
83cf136
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Dec 2, 2019
3d16176
Merge branch 'master' of https://github.com/pingcap/tidb into mpp
crazycs520 Dec 2, 2019
6545ba6
rename tidb_cluster to cluster and address comment
crazycs520 Dec 3, 2019
122564f
Merge branch 'master' into mpp
crazycs520 Dec 3, 2019
37e49e6
address comment
crazycs520 Dec 3, 2019
6474ceb
Merge branch 'mpp' of https://github.com/crazycs520/tidb into mpp
crazycs520 Dec 3, 2019
ea2286c
Merge branch 'master' into mpp
crazycs520 Dec 3, 2019
3cf354f
Merge branch 'master' into mpp
crazycs520 Dec 3, 2019
161597c
address comment
crazycs520 Dec 4, 2019
9a93bc1
Merge branch 'master' into mpp
crazycs520 Dec 4, 2019
c23366b
Merge branch 'master' into mpp
crazycs520 Dec 4, 2019
915977d
Merge branch 'master' into mpp
lonng Dec 4, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
check region id 0 before retry
  • Loading branch information
crazycs520 committed Oct 26, 2019
commit 85e601eb28619480a58f65240c696435d1c49427
5 changes: 5 additions & 0 deletions store/tikv/coprocessor.go
Original file line number Diff line number Diff line change
Expand Up @@ -849,6 +849,11 @@ func (worker *copIteratorWorker) handleCopStreamResult(bo *Backoffer, rpcCtx *RP
// successful response, otherwise it's nil.
func (worker *copIteratorWorker) handleCopResponse(bo *Backoffer, rpcCtx *RPCContext, resp *copResponse, task *copTask, ch chan<- *copResponse, lastRange *coprocessor.KeyRange, costTime time.Duration) ([]*copTask, error) {
if regionErr := resp.pbResp.GetRegionError(); regionErr != nil {
if rpcCtx.Region.id == 0 {
resp.err = errors.Errorf("error: %v", regionErr)
worker.sendToRespCh(resp, ch, true)
return nil, nil
}
if err := bo.Backoff(BoRegionMiss, errors.New(regionErr.String())); err != nil {
return nil, errors.Trace(err)
}
Expand Down
4 changes: 3 additions & 1 deletion store/tikv/region_request.go
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,9 @@ func (s *RegionRequestSender) onRegionError(bo *Backoffer, ctx *RPCContext, regi
logutil.BgLogger().Debug("tikv reports region failed",
zap.Stringer("regionErr", regionErr),
zap.Stringer("ctx", ctx))
s.regionCache.InvalidateCachedRegion(ctx.Region)
if ctx.Region.id != 0 {
Copy link
Contributor

Choose a reason for hiding this comment

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

Add comments for these checks and assumptions.

s.regionCache.InvalidateCachedRegion(ctx.Region)
}
return false, nil
}

Expand Down