Commit Graph

1179 Commits

Author SHA1 Message Date
xhe
b1edc33fc1 session: fix multiple domain creation racing in domap (#36792)
close pingcap/tidb#36791
2022-08-02 16:12:06 +08:00
c8cb3c96c8 planner: update plan cache key and value (#36779)
ref pingcap/tidb#36598
2022-08-02 15:26:05 +08:00
5b4a82dbf4 *: upgrade bazel timeout (#36776) 2022-08-02 11:10:05 +08:00
0b1d3e0da3 *: cleanup sysvar API usage (#36640)
close pingcap/tidb#36639
2022-08-02 07:54:04 +08:00
cc2fcfceca ddl/schematracker: fix SetDDL will cause data race (#36768)
close pingcap/tidb#36766
2022-08-02 00:24:05 +08:00
xhe
9a16a8dd19 *: replace defer clean with t.Cleanup (#36722)
close pingcap/tidb#36721
2022-08-01 17:34:05 +08:00
158ba1a1d9 *: enable part revive for all code (#36703) 2022-08-01 14:02:06 +08:00
1fe666add6 *: upgrade staticcheck (#36745) 2022-08-01 11:58:05 +08:00
1cd8c31b1a session: fix auto commit variable change effect on transaction commit (#36631)
close pingcap/tidb#36581
2022-08-01 09:36:04 +08:00
be102a3d55 *: fix timestamp conversion (#36705)
close pingcap/tidb#36707
2022-07-29 19:05:12 +08:00
58dae93f44 ddl: wait until there is an owner in the cluster (#36664)
close pingcap/tidb#36659
2022-07-28 19:43:11 +08:00
6baea73277 *: should replace errors.New(fmt.Sprintf(...)) with fmt.Errorf(...) (#36660) 2022-07-28 19:23:11 +08:00
15009a7c4e *: clean code (#36655) 2022-07-28 15:09:11 +08:00
5c42aae575 upgrade: add a variable to make insert ddl job force to queue (#36614)
close pingcap/tidb#36601
2022-07-27 17:33:12 +08:00
16f143f875 planner: refactor the execute path when using plan cache (#36587)
ref pingcap/tidb#36598
2022-07-27 12:31:10 +08:00
9d0f5f72d3 *: enable pessimistic transaction on unistore (#36578) 2022-07-26 21:07:10 +08:00
b0c6c5afa7 *: cleanup default sysvar value usage (#36487)
close pingcap/tidb#36485
2022-07-26 19:51:10 +08:00
87c5b5068a executor: do not acqurie pessimistic lock for non-unique index keys (#36229)
close pingcap/tidb#36235
2022-07-26 13:15:10 +08:00
893a114abc parser: fix DDL job.Clone() (#36523)
close pingcap/tidb#36522
2022-07-25 18:31:10 +08:00
63145482b5 session_test: move unnecessary tests out of realtikvtest (#36482) 2022-07-25 12:39:10 +08:00
8bc002e77c table partition: add telemetry for partition table (#36204)
close pingcap/tidb#34949
2022-07-22 11:53:09 +08:00
b377810979 session: Mising OptimizeWithPlanAndThenWarmUp in prepare-execute path (#36347)
close pingcap/tidb#36311
2022-07-21 22:01: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
d00b984f4c executor, statistics: analyze use MaxUint64 ts to read data (#35232)
close pingcap/tidb#35233
2022-07-20 16:09:08 +08:00
d48f40a09c util, session: enable paging for more ut (#36259)
ref pingcap/tidb#35633
2022-07-19 17:33:08 +08:00
5dcf2ef6ed telemetry: add telemetry for tidb_enable_paging (#36261)
close pingcap/tidb#36260
2022-07-18 15:59:07 +08:00
9a2ed52119 server, sessionctx: support token-based authentication (#36152)
close pingcap/tidb#35913
2022-07-14 18:29:06 +08:00
7953d60c1b *: switch to flat plan in stmt summary, slow log, etc (#36069)
ref pingcap/tidb#35888
2022-07-14 17:37:06 +08:00
2193bfe3b7 *: remove system var tidb_enable_change_multi_schema (#36167)
ref pingcap/tidb#14766
2022-07-14 10:37:05 +08:00
a0e4ba9dc6 planner: Reduce verbosity of logging unknown system variables (#36013)
close pingcap/tidb#36011
2022-07-13 15:57:06 +08:00
7458c3ec2e sessionctx: support signing and checking tokens (#36030)
close pingcap/tidb#36029
2022-07-12 20:33:05 +08:00
1a9a7a614c statistics,planner: let index support sync stats (#35879)
ref pingcap/tidb#35764
2022-07-11 17:23:05 +08:00
f3eb0f5c26 txn: remove NewTxn and NewStaleTxnWithStartTS in session (#35885)
close pingcap/tidb#35884
2022-07-07 19:27:02 +08:00
562b033689 telemetry: Initialize telemetry asynchronously (#35898)
close pingcap/tidb#35897
2022-07-06 17:35:02 +08:00
b40fc86538 session, sessionctx/variable: ensure sysvars are always in lower case (#35659)
close pingcap/tidb#35658
2022-07-06 16:49:02 +08:00
c76d686e67 *: add telemetry support for multi-schema change (#35977)
ref pingcap/tidb#14766
2022-07-06 16:27:03 +08:00
ec9f201294 topsql: compress plan instead of dropping it (#35973)
ref pingcap/tidb#35964
2022-07-06 16:03:02 +08:00
2df6be5282 *: Make the code cleaner in session.ExecutePreparedStmt (#35943)
close pingcap/tidb#35925
2022-07-06 12:51:02 +08:00
441c9cde30 txn: rename snapshot related methods in txnManager. (#35912)
close pingcap/tidb#35915
2022-07-05 12:37:01 +08:00
157c178f27 *: seperate TxnScope and ReplicaReadScope (#35877)
close pingcap/tidb#31772
2022-07-05 11:33:02 +08:00
e50b9430fc *: enable gci (#35823)
ref pingcap/tidb#35345
2022-07-04 14:53:02 +08:00
c836501f89 server, session: report an error when the session states cannot be fetched (#35892)
close pingcap/tidb#35866
2022-07-04 12:31:00 +08:00
e00ad2b3ef *: enable errcheck for nogo (#35704)
ref pingcap/tidb#35345
2022-07-02 22:08:39 +08:00
65e0b8e541 client: KV requests with source label (#34833)
close pingcap/tidb#33963
2022-07-01 19:46:39 +08:00
16e5815f18 txn: txnManager providers GetReadSnapshot and GetForUpdateSnapshot. (#35788)
close pingcap/tidb#35810
2022-07-01 18:12:40 +08:00
ff20343fda sessionctx, bindinfo: Support encoding and decoding session SQL bindings (#35861)
close pingcap/tidb#35847
2022-07-01 17:22:39 +08:00
556cf75ebd metric: Add transaction state's metric (#34845)
ref pingcap/tidb#34456
2022-07-01 16:56:40 +08:00
16df1942d0 *: add timeout for test cases (#35844) 2022-06-30 20:18:38 +08:00
11f39cd77a txn: unify the management of transaction activation by TxnManager. (#35679)
close pingcap/tidb#35705
2022-06-30 13:40:39 +08:00
4fc86936ff sessionctx: support encoding and decoding prepared statements (#35808)
close pingcap/tidb#35689
2022-06-30 11:56:38 +08:00