Commit Graph

54 Commits

Author SHA1 Message Date
55361cf75c linter: find inappropriate key in call to context.WithValue (#40769)
close pingcap/tidb#40796
2023-01-28 18:03:53 +08:00
669ba5cbae *: add warnings to slow log and slow query table (#39884)
ref pingcap/tidb#39893
2023-01-05 23:34:21 +08:00
xhe
4b3563c6cb *: forbid creation of normal files with exec perm (#36691) 2022-08-09 15:42:47 +08:00
a52656fde4 *: add binary plan in stmt summary and slow log/query (#35698)
close pingcap/tidb#35889
2022-07-20 18:21:09 +08:00
55aea2787d *: use pdqsort to improve sort performance (#34404)
close pingcap/tidb#34250
2022-07-06 13:41:02 +08:00
114c922bc8 *: enable gosec (#35873)
ref pingcap/tidb#35345
2022-07-05 19:39:01 +08:00
adebe4452b executor: fix time filter condition when select from information.slow_query_log (#34322)
close pingcap/tidb#34320
2022-05-10 10:56:33 +08:00
89410b537f executor: fix data race in TestSlowQueryOOM (#34016)
close pingcap/tidb#33982
2022-04-19 13:30:03 +08:00
d7aea072d6 executor: fix issue of query instance from CLUSTER_SLOW_QUERY return '' result (#33975)
close pingcap/tidb#33974
2022-04-15 12:18:36 +08:00
f988f54550 executor: add memory tracker for quering slow_query to avoid TiDB server oom (#33953)
close pingcap/tidb#33893
2022-04-14 14:54:36 +08:00
11681b4895 infoschema: add column of Has_more_result into table of slow_query (#33840)
close pingcap/tidb#33733
2022-04-11 11:50:34 +08:00
62ec7468e7 executor: fix goroutine leak in querying slow log (#32757)
close pingcap/tidb#32656
2022-03-03 12:49:46 +08:00
426a527a93 * : statement summary should know the slow write is blocked on read lock lease (#30166) 2021-12-01 09:47:53 +08:00
37bfd57dac *: support makezero via golangci-lint (#29267) 2021-11-10 17:05:06 +08:00
4aec743624 *: add IsExplicitTxn in slow log (#29413) 2021-11-04 14:09:02 +08:00
d5bd9f030b *: record result_rows in statements_summary and slow log (#28479) 2021-10-12 16:51:25 +08:00
xhe
94e30df8e2 parser: fix compiling, add unit tests (#28700) 2021-10-11 23:15:25 +08:00
d3b1d4bc31 *: fix parsing slow log incorrectly (#28160) 2021-09-29 10:04:46 +08:00
529fc03a9c slow_query: cancel send taskList if ctx is done (#27471)
* slow_query: cancel send taskList if ctx is done

Signed-off-by: tison <wander4096@gmail.com>
2021-08-23 12:08:34 +08:00
7755d25aba *: Integrate SkyWalking-eyes to check license headers in CI and fix licenses headers (#27198) 2021-08-16 18:52:00 +08:00
8f51a40798 *: optimize query slow query table by avoid decode plan for each row (#26219) 2021-07-19 16:33:34 +08:00
cb06e116c1 *: update the golangci-lint and fix all lint errors (#25912) 2021-07-05 13:43:27 +08:00
39bd181213 *: Upgrade to go 1.16 && remove deprecated io/ioutil (#24527) 2021-05-25 12:07:34 +08:00
c5ca2ea7f9 *: add security enhanced mode part 2 (#24279) 2021-04-30 00:31:57 +08:00
7f25d4f0cc executor, infoschema, planner: optimize query cluster_slow_query (#20750) 2021-01-04 14:23:06 +08:00
28c9e9290b *: gocritic fixes for commentFormatting (#21578) 2020-12-09 12:03:17 +08:00
43a562f60e *: fix cancel query slow_query doesn't release resource and tiny optimize (#21456) 2020-12-04 15:04:12 +08:00
32d19b78e1 *: refine runtime stats display and tiny bug fix for metrics (#21022)
Signed-off-by: crazycs520 <crazycs520@gmail.com>
2020-11-26 16:35:25 +08:00
ea3e4fa519 executor: fix bug when parsing the slow logs if the logNum is small (#20959) 2020-11-23 15:43:14 +08:00
2c66371d8b planner, sessionctx : Add 'last_plan_from_binding' to help know whether sql's plan is matched with the hints in the binding (#18017) 2020-11-20 20:43:23 +08:00
00458d0111 executor: fix the issue of query slow_query return 0 rows (#20497)
Signed-off-by: crazycs520 <crazycs520@gmail.com>
2020-10-21 12:04:27 +08:00
c808997d25 store, util: adapt scandetailv2 in coprocessor response (#20391) 2020-10-16 14:25:57 +08:00
5996c5681c *: Support query backoff detail in SLOW_QUERY and add runtime stats columns to STATEMENTS_SUMMARY、SLOW_QUERY (#20300) 2020-10-14 17:27:07 +08:00
0ed9f4d050 executor: tiny optimize slow_query performance and add related runtime stats (#20200) 2020-10-13 14:06:09 +08:00
aed24e46e2 executor: fix query slow_query error when slow-log file not exist (#20000)
Signed-off-by: crazycs520 <crazycs520@gmail.com>
2020-09-15 20:45:00 +08:00
f13d605273 executor: fix cluster_slow_query time type in streaming request bug (#19938)
Signed-off-by: crazycs520 <crazycs520@gmail.com>
2020-09-11 10:55:09 +08:00
5d3cdf5d17 *: add execution retry time in slow log and slow_query and statement_summary (#19625)
Signed-off-by: crazycs520 <crazycs520@gmail.com>
2020-09-01 11:16:52 +08:00
253d43fb51 *: add execution retry count in slow log and slow_query (#19487) 2020-08-27 14:18:06 +08:00
c04bda6db7 *:Speed up parse slow-log when query slow_query #15371 (#19139)
* speed up the slow log query

* speed up slow log query

* change the MaxRow num

* change channel location

* correct

* fix some bug

* fix error situation

* change ctx.Done() location

* update

* Update main.go

* change func name

* fix the len(rows)=0 bug

* remove else

* update slow_query_test

* update slow_query_test.go

* update slow_query_test.go

* update slow_query_test.go

* append offset var

* fix bug

* add notes

* remove fmt

* remove notes

* remove notes

* update

* update

* version back

* update offset

* update

* use len(log)==0 to check

* update

* update offset struct

* update offset

* defer recover

* update slow_query_test

* update offset

* remove fmt.print

* check error first

* update panic situation

* update failpoint test

* update failpoint test

* update panic test

* test

* test

* update test

* update failpoint name

* test

* update slow_query.go

* check err

* Code specification

* remove pointer

* update getLineIndex func

* update setFieldValue func

* debug

* update func name

Co-authored-by: crazycs <crazycs520@gmail.com>
Co-authored-by: ti-srebot <66930949+ti-srebot@users.noreply.github.com>
2020-08-25 19:00:22 +08:00
6a7ba4aafa executor: make the format of the DB field in slow logs be compatible with MySQL (#18389) 2020-07-13 18:39:41 +08:00
ef8ad55082 executor: make the format of user and host fields in slow logs be compatible with MySQL (#18162) 2020-07-06 10:40:21 +08:00
405a5d009d sessionctx: add optimization-time and wait-TS-time into the slow log (#17869) 2020-06-10 10:41:50 +08:00
0ec197fae0 sessionctx: add some information about the rewriting phase into the slow log (#17569) 2020-06-09 13:49:42 +08:00
55d9d6ca1e sessionctx,infoschema,executor,util: Show disk usage of a query in slow query and statement summary (#17132) 2020-05-26 22:03:40 +08:00
f5706c9099 executor: fix slow_query bug when query with time equal condition (#17225) 2020-05-15 18:28:53 +08:00
22f0c7f6c1 executor: fix slow_query bug when query with time equal condition and in different time zone (#17082) 2020-05-13 14:34:01 +08:00
cfec13772b sessionctx: record if a query hits plan cache in slow log (#17088) 2020-05-12 15:49:05 +08:00
3a07cf7fcc executer: add Cop_time in slow log (#16873) 2020-04-28 15:08:09 +08:00
5e4a694897 executor: fix slow_query bug when query with time equal condit… (#16768) 2020-04-24 19:13:13 +08:00
5bdc0eaf50 executor: fix slow_query bug when query with time equal condition (#16445) 2020-04-20 10:52:03 +08:00