Commit Graph

190 Commits

Author SHA1 Message Date
971deb6202 *: add a new I_S table and support show create for resource groups (#40665)
close pingcap/tidb#39781
2023-01-17 23:37:49 +08:00
cefb26146b executor: fix issue of KEY_COLUMN_USAGE table return wrong result about foreign key column (#40491)
Signed-off-by: crazycs520 <crazycs520@gmail.com>

Signed-off-by: crazycs520 <crazycs520@gmail.com>
Co-authored-by: Weizhen Wang <wangweizhen@pingcap.com>
Co-authored-by: Ti Chi Robot <ti-community-prow-bot@tidb.io>
2023-01-11 19:08:33 +08:00
19dae1fa73 *: separate auto_increment ID allocator from _tidb_rowid allocator when AUTO_ID_CACHE=1 (#39041)
close pingcap/tidb#982
2022-11-29 20:20:00 +08:00
15b523cb07 *: add a memdb memory tracker (#39372)
ref pingcap/tidb#35203
2022-11-25 19:03:59 +08:00
a8f56ee851 planner: support the view hint (#38653)
close pingcap/tidb#37887
2022-11-14 12:01:54 +08:00
835518122e DDL: Remove TiFlash replica progress etcd dependency (#38564)
close pingcap/tidb#38464
2022-10-31 13:37:59 +08:00
40f059a289 executor: add some memory tables to observe memory usage (#38452)
ref pingcap/tidb#37816
2022-10-28 15:05:59 +08:00
00169d2fe8 inforschema: check the user permission before loading TIKV_REGION_STATUS (#38627)
close pingcap/tidb#38407
2022-10-25 13:17:56 +08:00
41518c9e02 executor: fix getting the more result when select * from TIKV_REGION_STATUS where table_id=xx (#38601)
close pingcap/tidb#37499
2022-10-24 00:59:56 +08:00
4699c7d896 *: support ATTRIBUTE and COMMENT in CREATE USER and ALTER USER statements (#38201)
close pingcap/tidb#38172
2022-10-20 14:35:54 +08:00
dd65832136 *: add context for hook of getting/setting variables (#38379)
close pingcap/tidb#38378
2022-10-18 16:43:53 +08:00
78d3307852 executor: keep progress in information_schema.tiflash_replica two digits after the decimal point (#38415)
close pingcap/tidb#38412
2022-10-12 18:43:52 +08:00
e0ef093988 executor: fix null type print the wrong column type in infoschema (#38397)
close pingcap/tidb#38108
2022-10-12 11:27:50 +08:00
be5458261f executor, sessionctx/variable: small code improvements (#38181)
ref pingcap/tidb#38180
2022-10-09 17:03:49 +08:00
a4b8e9fa0c systable: Adapt with TiFlash system table update (#38191)
close pingcap/tidb#38192
2022-09-30 21:39:45 +08:00
319b32005e DDL: update TiFlash replica progress after available (#37766)
ref pingcap/tiflash#4902
2022-09-22 20:11:03 +08:00
ff1df75a6a *: add more tests for metadata lock and fix data race (#37930)
close pingcap/tidb#37927
2022-09-20 12:05:01 +08:00
c4638b70fd *: support metadata lock (#37393)
ref pingcap/tidb#37275
2022-09-18 20:57:00 +08:00
04a564ee46 *: fix data race in the statsCache (#37753)
close pingcap/tidb#37603
2022-09-13 12:20:59 +08:00
9036de3394 *: support create table with foreign key and maintain foreign key reference (#37148)
close pingcap/tidb#37147
2022-09-07 13:22:56 +08:00
77223af6a3 executor: fix incorrect ORDINAL_POSITION for INFORMAITON_SCHEMA.COLUMNS table (#37419)
close pingcap/tidb#31200
2022-09-06 08:08:55 +08:00
170dafc7e1 types: merge json and types pkg (#37578)
close pingcap/tidb#37577, close pingcap/tidb#37628
2022-09-05 19:42:55 +08:00
331707cfdc infoschema: check hidden sysvars for SEM (#37587)
close pingcap/tidb#37586
2022-09-04 13:32:26 +08:00
36ff60d042 planner: fix partition table getting error result when select TIKV_REGION_STATUS with table_id. (#37498)
close pingcap/tidb#37436
2022-09-02 11:54:25 +08:00
ccd4f347a2 *: Enable tiflash_fastscan variable and remove fast mode alter statment (#37027)
ref pingcap/tidb#35850
2022-08-29 11:28:22 +08:00
46cb6dc679 executor: fix column_default with timestamp and bit type (#36851)
close pingcap/tidb#36027
2022-08-04 15:30:06 +08:00
bf23ee9090 executor: invalidate infoschema's stats cache after analyze (#32803)
close pingcap/tidb#32693
2022-08-03 22:00:05 +08:00
0b1d3e0da3 *: cleanup sysvar API usage (#36640)
close pingcap/tidb#36639
2022-08-02 07:54:04 +08:00
158ba1a1d9 *: enable part revive for all code (#36703) 2022-08-01 14:02:06 +08:00
e7ee7e2280 executor: refine the error message for TABLE_STORAGE_STATS (#36464)
close pingcap/tidb#36403
2022-08-01 11:42:05 +08:00
6baea73277 *: should replace errors.New(fmt.Sprintf(...)) with fmt.Errorf(...) (#36660) 2022-07-28 19:23:11 +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
8c380e3107 ddl: support alter table options for multi-schema change (#36236)
ref pingcap/tidb#14766, close pingcap/tidb#36234
2022-07-18 10:39:07 +08:00
2f934d67a2 *: support show ddl jobs for sub-jobs (#36168)
ref pingcap/tidb#14766
2022-07-13 20:57:05 +08:00
e5487a94e0 perfschema: add session_variables table to performance_schema (#36003)
close pingcap/tidb#35894
2022-07-08 10:33:03 +08:00
6e22e47f06 parser,ddl: support 'set tiflash mode' ddl and support check tiflash mode in tiflash_replica table (#35851)
ref pingcap/tidb#35850
2022-07-07 15:15:03 +08:00
adab58b360 infoschema, executor: Add variables_info table to see sysvar details (#35995)
close pingcap/tidb#21446
2022-07-07 11:51:02 +08:00
55aea2787d *: use pdqsort to improve sort performance (#34404)
close pingcap/tidb#34250
2022-07-06 13:41:02 +08:00
65e0b8e541 client: KV requests with source label (#34833)
close pingcap/tidb#33963
2022-07-01 19:46:39 +08:00
df9b54bcb3 txn, session: Add (cluster_)trx_summary table (#28835)
ref pingcap/tidb#34457
2022-06-23 11:16:36 +08:00
d4dc6b54c6 *: enable staticcheck and prealloc on nogo (#35486)
ref pingcap/tidb#35345
2022-06-22 22:00:37 +08:00
f1694589f4 txn: Add lock resolving to data_lock_waits (#33993)
close pingcap/tidb#34609
2022-06-01 00:30:26 +08:00
d4df6b3c90 executor: get schema and outname of view once in the dataForColumnsInTable (#34658)
close pingcap/tidb#34657
2022-05-17 14:14:38 +08:00
e1ccd33247 executor: fix DATA RACE for reading information_schema.columns where there are views (#34538)
close pingcap/tidb#34509
2022-05-16 13:52:36 +08:00
f88dab92f9 util: use generics to implement max/min (#34197)
close pingcap/tidb#34247
2022-05-06 10:08:57 +08:00
1bf64c60f4 *: Refactor FieldType structure (#33569)
close pingcap/tidb#32116
2022-04-26 19:28:51 +08:00
e6d55e14fa executor/infoschema_reader.go: skip the unidentifiable table-attributes (#34129)
close pingcap/tidb#33665
2022-04-22 14:08:04 +08:00
0f4706418e *: track cluster-level analyze jobs and make it persistent (#32215)
close pingcap/tidb#32403
2022-03-31 21:06:29 +08:00
b35b30bbd5 executor: support extractor for mem table region status (#33498)
close pingcap/tidb#33348
2022-03-30 16:12:29 +08:00
c5a0737e56 executor, infoschema: Add foreign key constraint to infoschema.table_constraints (#33360)
close pingcap/tidb#28918
2022-03-25 17:24:34 +08:00