mirror of
https://github.com/MariaDB/server.git
synced 2025-01-29 02:05:57 +01:00
MDEV-31609 mtr: only print session tracking from the last statement
We do this by checking server status. By doing this we avoid printing session tracking info from previous (but not the last) statement. The change is from Sergei Golubchik
This commit is contained in:
parent
7bec41d25d
commit
e32736ec59
2 changed files with 2 additions and 8 deletions
|
@ -7948,6 +7948,8 @@ static const char *trking_info_desc[SESSION_TRACK_END + 1]=
|
|||
|
||||
static void append_session_track_info(DYNAMIC_STRING *ds, MYSQL *mysql)
|
||||
{
|
||||
if (!(mysql->server_status & SERVER_SESSION_STATE_CHANGED))
|
||||
return;
|
||||
#ifndef EMBEDDED_LIBRARY
|
||||
for (unsigned int type= SESSION_TRACK_BEGIN; type <= SESSION_TRACK_END; type++)
|
||||
{
|
||||
|
|
|
@ -11,10 +11,6 @@ create table t1 (a int) engine=innodb;
|
|||
select @@last_gtid;
|
||||
@@last_gtid
|
||||
0-1-1000
|
||||
-- Tracker : SESSION_TRACK_SYSTEM_VARIABLES
|
||||
-- last_gtid
|
||||
-- 0-1-1000
|
||||
|
||||
insert into t1 values (1);
|
||||
-- Tracker : SESSION_TRACK_SYSTEM_VARIABLES
|
||||
-- last_gtid
|
||||
|
@ -23,10 +19,6 @@ insert into t1 values (1);
|
|||
select @@last_gtid;
|
||||
@@last_gtid
|
||||
0-1-1001
|
||||
-- Tracker : SESSION_TRACK_SYSTEM_VARIABLES
|
||||
-- last_gtid
|
||||
-- 0-1-1001
|
||||
|
||||
drop table t1;
|
||||
-- Tracker : SESSION_TRACK_SYSTEM_VARIABLES
|
||||
-- last_gtid
|
||||
|
|
Loading…
Add table
Reference in a new issue