Commit Graph

161 Commits

Author SHA1 Message Date
36bcf5db4a tidb/kv: remove useless errors.Trace (#8527) 2018-11-30 14:30:31 +08:00
654c6a9888 session: add GoString() for TxnState and make the log more use friendly (#8434) 2018-11-29 10:30:39 +08:00
e7e31fae3f *: add preparedStmt metric and add limit to max prepareStmt (#8405) 2018-11-28 20:37:50 +08:00
H
bb7bb14fc3 support system variable wait_timeout. (#8245) (#8346) 2018-11-28 11:53:07 +08:00
cadab30b4a domain,session: simplify the session pool of domain (#8456) 2018-11-27 16:09:55 +08:00
1927cd9a30 session: release datum memory after transaction finished (#8458) 2018-11-27 15:37:12 +08:00
cb64314131 session: add current DB to CRUCIAL OPERATION log (#8447) 2018-11-26 21:24:44 +08:00
84d1299bb2 config, util.kvcache: support the memory guard to prevent OOM for the plan cache (#8339) 2018-11-22 22:05:04 +08:00
e69aa2749b server: unix socket should verify user's authentication (#8381) 2018-11-22 13:43:38 +08:00
f085f4fee4 admin: admin check table/index using tidb_snapshot (#8172)
* admin: admin check table/index support snapshot
2018-11-22 12:21:53 +08:00
89cd59d217 planner/core,session: fix privilege check for update (#8376)
In the statement: "update t1,t2 set t1.id = t2.id"
TiDB should check update privilege for t1 and select privilege for t2,
Fix a bug that it checks update privilege for both t1 and t2
2018-11-21 18:15:13 +08:00
6fb260f8a6 *: redesign trace statement with json output (#8357) 2018-11-21 13:50:18 +08:00
61ee0da103 planner: cleanup prepare cache when client send deallocate (#8332) 2018-11-20 12:33:44 +08:00
8ddbd7062e session: fix bootstrap error in ANSI sql_mode (#8353) 2018-11-20 11:25:49 +08:00
3742a0d602 *: Txn() function signature refactor and remove ActivePendingTxn() (#8327)
* change Txn() function signature to Txn(active bool)
* ActivePendingTxn() is not used any more because Txn() does the work
* change executor builder getStartTS() uint64 to getStartTS() (uint64, error)
2018-11-16 11:10:39 +08:00
0c3e9c1652 session,executor: run statement without transaction (#8260)
`set @@autocommit = 0`
`select 1` // This statement should not make the session enter a transaction,
because it never need Txn().
Make txn lazy initialize
2018-11-14 20:10:58 +08:00
dcba7eac00 session: add sql types for commit and retry (#8281) 2018-11-14 16:40:27 +08:00
ce6a7150b3 executor: Support NO_AUTO_CREATE_USER sql mode (#8160) 2018-11-12 13:45:37 +08:00
877cbd33c7 *: spilt the internal SQLs in the transaction related metrics (#8255) 2018-11-09 20:47:36 +08:00
d125958380 tikvclient: Add endKey param to Scanner (#8178) 2018-11-08 18:21:40 +08:00
81d2fff83c store/tikv: refine backoff log (#8207) 2018-11-08 15:56:01 +08:00
9fdc8ebe5d session: add transaction start timestamp to the log when retrying (#8091) 2018-11-07 16:12:39 +08:00
32b1dbd8d5 *: rename "github.com/pkg/errors" to "github.com/pingcap/errors" (#8136)
We import "github.com/pkg/errors" in the code, and actually put
the "github.com/pingcap/errors" there in the vendor path.
That's a dirty hack, and prevent the introduce of Go module.
2018-11-01 16:09:07 +08:00
696ef7bae2 plan: convert in subquery to agg and inner join (#7531) 2018-10-30 19:19:32 +08:00
508f5dd626 binlog: use pumps client to write binlog (#8070) 2018-10-27 17:52:01 +08:00
89dda9d9a8 *: move parser to a separate repository (#8036) 2018-10-25 11:12:10 +08:00
edaec7bdaf *: move Statement and RecordSet from ast to sqlexec package (#7970) 2018-10-21 13:21:26 +08:00
25118db843 *: move ast.NewValueExpr to standalone parser_driver package (#7952)
Make the ast package get rid of the dependency of types.Datum
2018-10-19 19:37:55 +08:00
b7a8f91e0a executor: add the slow log for commit (#7951) 2018-10-18 22:59:04 +08:00
f3148da27f executor: add an variable to compatible with MySQL insert for OGG (#7863) 2018-10-17 10:19:04 +08:00
19e4e2fa9f expression: MySQL compatible current_user function (#7801) 2018-10-16 13:53:07 +08:00
a8f2909d40 *: remove kv.BypassLatch option and enable latch scheduler by default (#7882)
kv.BypassLatch was introduced to handle the fake transaction confliction problem
in the old implementation. After redesign of the latch scheduler, it's not
needed any more.

Enable latch scheduler makes CI to run it, we can fix bugs and make this feature
more stable.
There is a small performance penalty, less than 5%, users are free to disable it.
2018-10-15 13:49:38 +08:00
48704b8420 *: fix Command and Time in show processlist (#7844) 2018-10-12 14:06:54 +08:00
dbdd806c0e *: add session variable "tidb_enable_cascades_planner" (#7879) 2018-10-12 13:21:51 +08:00
db151bb66f domain: fix memory leak for stats (#7864) 2018-10-11 10:58:22 +08:00
ee0d4d6c64 executor: print arguments in execute statement in log files (#7684) 2018-10-09 15:24:25 +08:00
05666f5ad3 session: set Sleep state for process info (#7826) 2018-10-08 12:38:55 +08:00
05b37de16e *: use chunk grow for simple executor (#7540) 2018-09-27 09:07:51 +08:00
e79bd946ed *: change package name from plan to planner (#7760) 2018-09-25 11:16:39 +08:00
038ac639ba expression: ECB/CBC modes with 128/192/256-bit key length for AES (#7425) 2018-09-23 22:09:02 +08:00
29441950a3 *: write system timezone into mysql.tidb in bootstrap stage. (#7638) 2018-09-14 22:15:00 +08:00
cb03f2bec1 move from juju/errors to pkg/errors (#7151) 2018-09-12 15:42:20 +08:00
8c44f562f5 metrics: add different labels for restricted SQL and general SQL (#7631)
The newly added label is `sql_type`, it has value: `general` and `internal`,
users can use this label to filter metrics they have interest.

Also, add keyword `[INTERNAL]` for restricted SQL printed in slow log for
convenient identification.
2018-09-07 14:23:48 +08:00
6e3bbe8e35 *: add HIGH_PRIORITY for the bootstrap SQLs. (#7616) 2018-09-06 00:49:12 +08:00
56f5ff8e09 Use TSO instead of seconds in gc_delete_range table (#7610) 2018-09-05 18:51:18 +08:00
341dc1009c *: tidb tracing prototype (#7016) 2018-08-31 05:25:16 +08:00
5b689e8c5b server: fix insert zero timestamp bug with prepared statement (#7506) 2018-08-28 13:36:36 +08:00
98d2a03136 session:don't use utc to created a customized timezone but empty string (#7424) 2018-08-21 17:31:29 +08:00
6e7d75299d test: refine test (#7414) 2018-08-16 17:05:59 +08:00
3d7d81c868 fix etcd watcher goroutine leak test failure (#7408) 2018-08-16 15:15:01 +08:00