Commit Graph

14 Commits

Author SHA1 Message Date
ffea45b718 ddl: enable linter revive (#44380)
ref pingcap/tidb#40786
2023-06-03 05:11:39 +00:00
65959f3e91 ddl: fix a bug that upgrade the node when there is a paused job. (#44231)
close pingcap/tidb#44225
2023-05-29 08:36:41 +00:00
6676ca8160 ddl: split some tests into new package (#40758)
ref pingcap/tidb#40802
2023-01-29 14:29:54 +08:00
005c8d8ef8 *: remove the support of the amending transaction (#39714)
close pingcap/tidb#40381
2023-01-06 18:26:21 +08:00
9784615566 ddl: Add index fast path to be a default add index path (#39267)
ref pingcap/tidb#35983
2022-11-23 15:45:58 +08:00
c4638b70fd *: support metadata lock (#37393)
ref pingcap/tidb#37275
2022-09-18 20:57:00 +08:00
xhe
9a16a8dd19 *: replace defer clean with t.Cleanup (#36722)
close pingcap/tidb#36721
2022-08-01 17:34:05 +08:00
ab513bf0ca ddl: support concurrent ddl (#32169)
* 1. init ddl tables

create tidb_ddl_job, tidb_ddl_reorg, tidb_ddl_history tables with raw meta write, these 3 tables is use to replace the ddl job queue and reorg and history hash table

* 2. setup concurrent ddl env and add ddl worker pool

adds the ddl worker pool definition, the ddl job manager will find a job and ship it to a worker in the worker pool.
Also, this commit provides a sessionctx wrapper, only use in ddl relate. it just wraps begin, commit and execute

* 3. add ddl manager to handle ddl job

* 4. reorg handler for concurrent ddl

just implements the partner of the reorg information.

* 5. manage ddl jobs for concurrent ddl

add the partner of add job, delete job and many others related to history job
because many of the functions need a session now, we just change the caller

* 6. add metrics for concurrent ddl

add metrics

* 7. support multiple tables

* 8. fix test

* 9. migrate ddl between table and queue

support switch between the old and new ddl framework, migrate the existing ddl job between queue and table

* 10. check tikv version and set reorg worker count according cpu count

* *: add featuretag on tests

Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>

* use a determined table id for 3 tables

* remove ctx value

* add GetSchemaVersionWithNonEmptyDiff function

* address tangenta and zimulala comment

* use only one etcd path

* make ActionRenameTable support multi-schema

* reset sql digest to make top sql work correct

* add comment

* fix test

* remove 0 for schema version lock

Co-authored-by: xiongjiwei <xiongjiwei1996@outlook.com>
Co-authored-by: Ti Chi Robot <ti-community-prow-bot@tidb.io>
Co-authored-by: wjHuang <huangwenjun1997@gmail.com>
2022-07-20 21:20:07 +08:00
0f4641aaf0 ddl: fix wrong default value (#34947)
close pingcap/tidb#34881
2022-06-07 10:22:29 +08:00
7f023bd61b ddl: wrap some functions for ddl job (#34920)
close pingcap/tidb#34919
2022-05-29 15:38:26 +08:00
73f3435346 ddl: move some admin function to ddl (#34527)
close pingcap/tidb#34526
2022-05-10 18:14:34 +08:00
40a70a3928 ddl: remove race skip for test (#33324)
close pingcap/tidb#31716
2022-03-23 12:42:33 +08:00
ef8c858347 ddl: migrate test-infra to testify for ddl.testDBSuite4 (#33113)
close pingcap/tidb#32964
2022-03-16 11:49:52 +08:00
9c25b3e3ea ddl: migrate test-infra to testify for repair table tests (#32958)
close pingcap/tidb#32954
2022-03-09 17:27:49 +08:00