This repository was archived by the owner on Jul 24, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 100
*: merging tidb-lightning #665
Merged
Merged
Changes from all commits
Commits
Show all changes
362 commits
Select commit
Hold shift + click to select a range
870be6f
add code coverage badge and build status (#130)
zhouqiang-cl 10b9033
restore: limit closed engine count for coordinating `write` and `impo…
lonng b345961
add roadmap (#133)
IANTHEREAL 9b71f1c
restore: write index kv pairs and data kv pairs to separate engine (#…
lonng 9c6a5f6
Support CSV (#111)
kennytm acc626d
update version of tidb to latest release-2.1 (#138)
WangXiangUSTC e15468e
tidb-lightning-ctl: added --import-engine and --cleanup-engine comman…
kennytm 6a64363
*: parameter type fix (#141)
amyangfei 5c69d10
remove changelog and get change logs from release (#146)
IANTHEREAL 59b0f24
test: fix cleanup script to enable re-run integration test locally (#…
amyangfei 76bd3e1
restore: fix #140 lightning breaks on tidb-master (#147)
lonng 852c5e9
fix deadlock and goroutine leak in chunk restore (#149)
IANTHEREAL d2e15ca
restore: eager release index engine worker after imported (#150)
lonng 9991839
checkpoint: fix checkpoint not updated in some scenario (#151)
amyangfei c3886a8
Revert "fix deadlock and goroutine leak in chunk restore (#149)" (#152)
IANTHEREAL 80f7c41
restore: add local checksum log (#153)
lonng 82ed51b
tests: add kill lightning test in checkpoint_chunks case (#158)
amyangfei 7bae12e
*: parse the data source directly into data and skip the KV encoder (…
kennytm 43fdfc3
tests: fix a test failure due to conflict between #145 and #158 (#159)
kennytm c14d62a
restore: give priority to small tables for importing (#156)
lonng 3f468b3
config: Allow overriding some config from command line (#157)
kennytm c103cd1
go.mod: upgrade dependencies, esp TiDB -> v3.0.0-beta.1 (#160)
kennytm fcbafa0
Fix interpretation of integers in a BIT column (#161)
kennytm ea3b27e
*: replace gofail with new failpoint implementation (#165)
lonng a515465
*: use pingcap/log (zap) for logging (#162)
kennytm 2f304e1
main: sync log before exit + update failpoint dep (#168)
kennytm 9adb660
kv: fix handling of column default values (#170)
kennytm 9b895b6
tests,restore: re-enable the exotic_filenames test (#172)
kennytm 889ce1b
config: reduce default table-concurrency from 8 to 6 (#175)
kennytm 748f7e2
Support table routing rules (merging sharded tables) (#95)
kennytm c8ead05
tests: removes the emoji from a test database name (#179)
kennytm d477eaf
*: fix failpoint-ctl path, unify failpoint runtime and ctl to same ve…
amyangfei a3cda85
restore: fix the potential null pointer exception when logging progre…
kennytm 877e839
kv,restore: log which value caused conversion failure (#154)
kennytm dd21072
restore: retry if deliver KVs to importer (#176)
lonng f8385c7
config: automatically discover tidb.pd-addr and tidb.port if not prov…
kennytm 7bb11c2
*: added linters (#183)
kennytm 00d4c68
common: improve unit test coverage of 'common' package (#186)
lonng 973244e
common: improve unit test coverage of 'kv' package (#187)
lonng f4512ae
Make the parsers stricter, and improve unit test coverage of `mydump`…
kennytm 08657c6
lightning: improve unit test coverage of 'lightning' package (#188)
lonng 4d01a9b
README: update coverage status badge (#189)
lonng e98dbf8
config: improve unit test coverage of 'config' package (#192)
lonng 78bb37c
Add unit tests for kv/importer and restore/checkpoints, plus some bug…
kennytm bcddb57
Add unit tests for 'restore.go' (TableRestore and chunkRestore) (#193)
kennytm 3256747
go.mod: update dependencies (#197)
kennytm 9fec239
config,lightning: Implements server mode (#198)
kennytm 9d55221
go.mod: update dependencies (#200)
kennytm 8601657
Post restore config fix (#202)
ericsyh adda917
Introduce a basic web interface (#199)
kennytm 7097f66
Update README.md (#207)
lance6716 54796d7
Improve errors and logs on syntax error / conversion failure (#201)
kennytm ba6a2d2
tests,web: exclude these directories from the Go module (#209)
kennytm 69e76c2
lightning/restore: fix ColumnPermutation calculation (#210)
lonng f3af17a
build(deps): bump lodash from 4.17.11 to 4.17.14 in /web (#213)
dependabot[bot] 5218dd6
*: adjust solution for TOOL-1420 and add a test case (#214)
kennytm cf08f2f
tests: add test case for simple partitioned tables (#206)
kennytm 666c34e
checkpoints: remove node_id field and rename the schema on keep-after…
kennytm 034ba60
config: attempt to solve TOOL-1405 and modify old test cases (#217)
lance6716 ae59251
restore: fix gc life time not recovered after table restore (#218)
amyangfei af34025
*: abstract the Importer communication into an interface (#215)
kennytm e8d463a
restore: update and restore GCLifeTime once when parallel (#220)
lance6716 4eb74ec
*: support MySQL backend (#221)
kennytm 1577f31
config: always skip the system databases (#225)
kennytm ce5fa5f
backend: update mysql backend to tidb backend (#228)
WangXiangUSTC 56c3c04
lightning/common: add unit test (#229)
WangXiangUSTC befa68a
mock: update rpc endpoint (#226)
lance6716 ab23466
cmd: do not exit(1) if failed to sync log (#230)
kennytm 7ecd9ad
mock: update rpc endpoint (#234)
lance6716 d49fec6
backend: dynamically calculate the maximum auto-inc ID (#227)
kennytm aaac2b4
checkpoint: fix empty map become nil after unmarshall (#237)
lance6716 b7d4675
config: increase default concurrency (#244)
lance6716 b38da1e
backend/tidb: use REPLACE INTO or INSERT IGNORE INTO to provide idemp…
lance6716 3052939
*: use fixed timestamp to ensure import stability wrt CURRENT_TIMESTA…
kennytm 7dbd0c6
*: update dependencies (tidb -> 3.0.4) (#246)
kennytm 0edbc12
improve the log when encountering invalid checkpoint (#247)
kennytm 605760d
config: adding `[tidb] max-allowed-packet` config (#248)
kennytm 8d57e70
Fix +incompatible suffix not allowed error reported by go mod (#249)
suzaku 99e1ed0
allow use a separate pauser instead of global pauser (#251)
61a64ad
Add password as command line argument (#253)
42b7585
metrics: copy the grafana board into this repo (#256)
kennytm f9f6d8b
*: Update dependencies and fix unit test on Windows (#254)
kennytm b865826
config: synchronize actual default value with the toml file (#255)
kennytm bab3bc1
lightning: ensure the web interface still works outside server mode (…
kennytm 4348bb1
Upgrade TiDB to 4.0.0-beta, and recognize @@tidb_row_format_version =…
kennytm 9068e31
Support TLS; Reduce the need of config.toml in integration tests (#270)
kennytm e57567b
backend: define a reusable BufStore when creating a new session (#274)
kennytm 619c2dc
Update Chinese doc url (#276)
kennytm 093ce9f
Set session var for every new conn (#280)
july2993 3c8f4d7
lightning: split large csv file if possible (#272)
XuHuaiyu bf3c830
send a batch of kv in encodeLoop (#279)
XuHuaiyu f53609a
Replace CSV Ragel parser by a hand-written parser copied from encodin…
kennytm 0f54c30
backend: fix issue 282 (#283)
kennytm 98bc849
optimize the performance of lightning (#281)
july2993 56d0f7d
Some SwitchMode improvements (#287)
kennytm c0cbeb5
go.mod,web: update dependencies (#289)
kennytm b21f9ed
Support store version format generated by `git describe --tags` (#295)
solotzg 8153e31
Warn for single large file, change switch mode log level to info (#315)
lichunzhu f3ce13e
restore: fix typo (#304)
kennytm 3c3fa29
print lightning log to local file (#313)
lichunzhu c10636e
*: avoid accessing internal ports when backend=tidb (#312)
kennytm 18cd93c
config: remove strict mode from default SQL mode (#316)
kennytm edfa861
check table id when loading checkpoint (#317)
lichunzhu 391db4a
update tidb-tools to latest (#319)
3pointer 18b82fb
support alter random && update tidb dependency to latest (#324)
3pointer cc190c1
backend: add local kv storage backend to get rid of importer (#326)
glorv 99f6933
make lightning compatible with allow_auto_random_explicit_insert (#328)
3pointer 368d52e
config: update example config file (#331)
glorv 5b3b811
Fix test cases on release-3.0 (#330)
kennytm 369eaed
optimize parse csv and local backend write tikv (#334)
glorv 1dbbf30
fix checkpoint cleanup (#336)
glorv f8a9b65
lightning: fix web page not showing when not using server mode (#337)
kennytm cd6210d
config,mydumper: replace black-white-list by table-filter (#332)
kennytm 4af19d5
optimize encoder and adjust some config (#338)
glorv 25256f7
log: fix log file path (#345)
glorv 3d6a4db
fix local backend index split range (#347)
glorv 31c4b90
add log for environment http proxy setting (#340)
glorv f38aa6e
do not always change auto increment id (#348)
glorv 73e48bb
server: check open file ulimit for local backend (#343)
glorv 26a0f71
restore: do not rebase auto-id or generate auto row id for table with…
glorv 32c2868
Fix verbose log message for shell (#352)
d00b370
local: fix batch split retry alway failed error (#356)
glorv aaee763
backend: fix handling of empty binary literals (#357)
kennytm 94f7216
add log when execute statement failed (#359)
glorv 1dc2d6a
check checkpoint schema (#354)
glorv d1024a2
parser: fix csv parse header with empty line (#364)
glorv f376161
restore: fix missing colum infos when restore from checkpoint (#362)
glorv d3dc3ea
local: fix import with common handle (#367)
glorv f18863a
restore: don't switch mode in tidb backend (#368)
glorv 52a84b0
restore: support split csv source file with header (#363)
glorv b1b93fd
restore: support file level routing (#366)
glorv daa94d0
tidb_tools: update dependency (#371)
3pointer 417d55f
restore: check header columns (#372)
glorv 9fde4aa
web: update dependencies (#374)
kennytm 0630432
backend: update committs from unix timestamp to pd tso (#379)
3pointer 81e6118
update pd dependencies (#380)
glorv ee94dc5
local: return error if write to tikv returns no leader info (#381)
glorv 63c72b3
encoder: check string value for tidb encoder (#378)
glorv c017df5
Fix running unit tests on Windows (#375)
kennytm e4da649
checkpoint: verify checkpoint when resume from checkpoint (#376)
glorv 75fcfbe
test: change integration test script to allow run tests in parallel (…
glorv 3cee9d5
backend: split and ingest region size more precise (#369)
glorv 134c944
wait checkpoint finished if exit before success (#386)
glorv d23cf02
restore: support restore from s3 (#361)
glorv 3c11d2e
backend: fix sample when split region size is small (#387)
glorv 12fe8b1
backend: use peer address as grpc addr for tiflash store (#392)
glorv 6e39bb8
loader: fix store.WalkDir return inaccurate file size for soft link s…
glorv 81965be
fix chunk checkpoint may reset offset and row id (#395)
glorv 8ec7eff
make tiflash test more stable (#397)
glorv b4dc94b
test: fix integration test for 3.x version (#390)
glorv 4ea4e76
test: make start tiflash optional in integration test (#398)
glorv 6e4c898
restore: support restore apache parquet format source files (#373)
glorv e8c9b88
backend: fix load partition table with local backend (#402)
glorv cc3f809
lightning: support dynamically modifying the log level (#393)
kennytm e29c752
Check Lightning version when reusing checkpoint (#383)
kennytm e4de23b
support new collation for kv encoder (#407)
glorv bce9977
mydump: support multi bytes csv delimiter and separator (#406)
glorv 43b0914
backend: always retry ingest and get region if it's retryble (#405)
glorv a83a72e
Add license scan report and status (#399)
fossabot 5972027
mydump: fix infinite loop in ExportStatement when Read() returns non-…
kennytm 4fa18d1
lightning: start the HTTP server when receiving SIGUSR1 (#415)
kennytm e35cdcd
backend/tidb: fix issue 410 (#412)
kennytm e9b79ee
config: fix error on `-d 'C:\Windows\Path'` (#411)
kennytm aa029d8
local: fix infinity loop in retry get region (#418)
glorv da84e5d
backend: speed up uploading by open multi TCP connections (#400)
YuJuncen 60c1c27
post-restore: add optional level for post-restore operations (#421)
glorv 2660ffe
backend/local: do not retry epochNotMatch error when ingest sst (#419)
glorv 44d81ba
restore: disable some pd scheduler during restore (#408)
glorv 144bacc
log: simplify some warn log and do retry write for epoch not match er…
glorv c11e6bd
fix test (#426)
glorv 5b212bf
backend: fix a bug about wrong column info (#420)
78e064d
restore: better estimate task remain time progress log (#377)
glorv aa83de1
checksum: use gc ttl api for checksum gc safepoint in v4.0 cluster (#…
glorv 3ecec63
backend/tidb: add rebase auto id for tidb backend (#428)
glorv 6887f4e
fix autoid for v4.0.0 (#430)
glorv 4d97351
make: hide go.mod to resolve cyclic dependency with tidb (#439)
lance6716 8013216
config: support encode PostOpLevel and Duration as input (#441)
lance6716 eb609ec
restore: fix several bugs related to column permutations (#437)
glorv a1ac978
dep: update uuid dependency to latest google/uuid (#452)
lance6716 176d053
tidb-lightning-ctl: change default of -d to 'noop://' (#453)
kennytm 25a3711
restore: fix the bug that gc life time ttl does not take effect (#448)
glorv 66281df
config: filter out all system schemas by default (#459)
kennytm 66ac09a
backend: fix auto random default value for primary key (#457)
glorv f4354c9
mydumper: fix parquet data parser (#435)
glorv 51d0e7b
backend/local: use range properties to optimize region range estimate…
glorv 780143a
fix pd service id is empty (#460)
glorv 0e8cef2
fix s3 parquet reader (#461)
glorv 963829f
fix service gc ttl again (#465)
glorv 1d396c9
mydumper: verify file routing config (#470)
glorv ccf7f3c
config: allow four byte-size config to be specified using human-reada…
kennytm 7e17f97
test: change double type syntax (#474)
lance6716 a78137f
restore: add `glue.Glue` interface and other function (#456)
lance6716 da8b24e
glue: add GlueCheckpointDB and remove external TiDB usage (#478)
lance6716 2644a19
*: replace context.Backend with app context (#468)
glorv f5b98ef
restore: wait sub task finish before exit (#485)
glorv 16c7217
mydumper: convert parquet columns to lower case (#479)
glorv 91ca438
test: fix an unstable integration test (#492)
glorv 05bad62
mydumper: optimize parquet reader performance (#482)
glorv a15013c
restore: let the tikv checksum manager respect the DistSQLScanConcurr…
kennytm fbb62fa
support restore view (#417)
glorv cbad36a
backend/local: more robust range retry strategy (#476)
glorv 8a276c0
backend/local: batch split region with batch limit (#487)
glorv b460fcf
kill tiflash by name (#499)
glorv 95e4aa2
.github: let challenge-bot recognize the default SIG (#498)
kennytm a7fb063
backend: support stored generated columns in local/importer backends …
kennytm e363572
backend/local: check and return iter.Error when pebble is not valid (…
glorv a0b12ac
backend,restore: duplicate more important system variables from downs…
kennytm e0ffa0f
backend/local: set pebble db max file limit (#501)
glorv 7cb623e
mydump: fix issue 519 (#521)
kennytm 2fdd481
backend/local: remove useless and buggy truncate key (#516)
glorv 4fd9cd6
restore: apply adjust max-pending-peer-count when stop pd schedulers …
glorv 56bc32d
backend/local: fix next key (#523)
glorv ff241c3
backend: import planner/core package to initialize expression.Rewrite…
e9a1bfb
*: add some error description (#527)
glorv c2b6dde
test: fix unstable integration test auto_random_default (#529)
glorv 7622f91
post-process: support run table analyze after all tables are finished…
glorv c3fc041
encode retry split key (#531)
glorv 8510040
restore: fix error lost in create schema (#530)
3pointer 463e728
mydumper: update br to apply auto retry s3 read error (#533)
glorv f842ab8
Sort index rather than insert it into skiplist (#520)
Little-Wallace 1c04266
*: redact log and error messages, add log-redact parameter (#538)
lichunzhu 1f02abc
mydumper: do not remove more than 1 sep if trim last sep is true (#535)
glorv b23840d
restore: add error retry for checksum by tikv (#537)
glorv d1becd4
post-process: allow run checksum at last and restrict the number of c…
glorv d89fe86
restore: don't change TiDB config to support lightning via SQL (#545)
lance6716 1709cc7
restore: check row value count to avoid unexpected encode result (#528)
glorv a401ad0
restore: Try to create tables in parallel (#502)
hidehalo 0529577
Compatible for disk quota (#543)
Little-Wallace d9254b1
*: add method to check whether need local SST of table (#491)
lance6716 161f005
backend/local: skip split regions if engine total size is smaller tha…
glorv 0c9788e
config: change redact log parameter name (#547)
lichunzhu deb5243
backend/tidb: temporarily disable the strict-mode value check in tidb…
glorv 90dbfe3
test: fix invalid failpoint and integration test (#510)
glorv a098961
test: fix s3 integration test (#555)
glorv 5b63605
grafana dashboards support multiple cluster (#556)
9f87f4e
metrics: use tidb_cluster label get variable values (#559)
6c382e2
restore: add importing progress and optimize the accuracy of restore …
glorv c69c738
backend/local: fallback retryIngest to retryWrite (#554)
glorv 1f12021
backend: implement disk quota (#493)
kennytm 8e1f2d7
Add 'pkg/lightning/' from commit '1f120218b385d40702d7061830803cb11c1…
overvenus e9af8c2
*: replace pingcap/tidb-lightning with pingcap/br/pkg/lightning
overvenus f94a1a5
tests: enable TLS by default
overvenus 558e190
tests: adjust success message and shrink tikv reserve space
overvenus b36326e
tests, pkg/lightning: migrate lightning test view
overvenus 5380d49
tests: migrate lightning rest tests
overvenus ac8e315
lightning: move web to root directory
overvenus 87ed628
*: flatten lightning packages
overvenus 050aea4
cmd: flatten br/cmd packages
overvenus 9b0ba1b
*: add challenge-bot.yml and address review comments
overvenus ff44e7e
*: update go mod and add TLS support for log restore
overvenus File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| *_generated.go linguist-generated=true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,24 @@ | ||
| --- | ||
| name: "\U0001F914 Question" | ||
| labels: "type/question" | ||
| about: Usage question that isn't answered in docs or discussion | ||
|
|
||
| --- | ||
|
|
||
| ## Question | ||
|
|
||
|
|
||
| <!-- | ||
|
|
||
| Before asking a question, make sure you have: | ||
|
|
||
| - Searched existing Stack Overflow questions. | ||
| - Googled your question. | ||
| - Searched open and closed [GitHub issues](https://github.com/pingcap/br/issues?q=is%3Aissue) | ||
| - Read the documentation: | ||
| * [BR documentation](https://docs.pingcap.com/tidb/stable/backup-and-restore-tool) | ||
| * [Lightning documentation](https://docs.pingcap.com/tidb/stable/tidb-lightning-overview) | ||
| * [BR 中文文档](https://docs.pingcap.com/zh/tidb/stable/backup-and-restore-tool) | ||
| * [Lightning 中文文档](https://docs.pingcap.com/zh/tidb/stable/tidb-lightning-overview) | ||
|
|
||
| --> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| defaultSigLabel: sig/migrate |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,15 +1,15 @@ | ||
| br | ||
| bin/ | ||
| _tools/ | ||
| .idea/ | ||
| backupmeta | ||
| /br | ||
| /bin | ||
| /.idea | ||
| *.log | ||
| *.ngo | ||
| *.coverprofile | ||
| coverage.txt | ||
| docker/data/ | ||
| docker/logs/ | ||
| /docker/data/ | ||
| /docker/logs/ | ||
| *.swp | ||
| .DS_Store | ||
| go.mod | ||
| go.sum | ||
| /go.mod | ||
| /go.sum | ||
|
|
||
| # for the web interface | ||
| web/node_modules/ | ||
| web/dist/ |
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| // Copyright 2020 PingCAP, Inc. Licensed under Apache-2.0. | ||
|
|
||
| package cmd | ||
| package main | ||
|
|
||
| import ( | ||
| "bytes" | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Shall it be
br?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.
Do you mean
package br?