diff options
Diffstat (limited to 'mysql-test/suite/perfschema/include')
5 files changed, 66 insertions, 33 deletions
diff --git a/mysql-test/suite/perfschema/include/connection_load.inc b/mysql-test/suite/perfschema/include/connection_load.inc index 16fc136f842..02c8e2adbe1 100644 --- a/mysql-test/suite/perfschema/include/connection_load.inc +++ b/mysql-test/suite/perfschema/include/connection_load.inc @@ -186,10 +186,45 @@ call dump_all(); --connection default --disconnect con4a + +# Wait for the disconnect to complete +let $wait_condition= + select count(*) = 5 from performance_schema.threads + where `TYPE`='FOREGROUND' and PROCESSLIST_USER like 'user%'; +--source include/wait_condition.inc + --disconnect con4b + +# Wait for the disconnect to complete +let $wait_condition= + select count(*) = 4 from performance_schema.threads + where `TYPE`='FOREGROUND' and PROCESSLIST_USER like 'user%'; +--source include/wait_condition.inc + --disconnect con4c + +# Wait for the disconnect to complete +let $wait_condition= + select count(*) = 3 from performance_schema.threads + where `TYPE`='FOREGROUND' and PROCESSLIST_USER like 'user%'; +--source include/wait_condition.inc + --disconnect con5a + +# Wait for the disconnect to complete +let $wait_condition= + select count(*) = 2 from performance_schema.threads + where `TYPE`='FOREGROUND' and PROCESSLIST_USER like 'user%'; +--source include/wait_condition.inc + --disconnect con5b + +# Wait for the disconnect to complete +let $wait_condition= + select count(*) = 1 from performance_schema.threads + where `TYPE`='FOREGROUND' and PROCESSLIST_USER like 'user%'; +--source include/wait_condition.inc + --disconnect con5c # Wait for the disconnect to complete diff --git a/mysql-test/suite/perfschema/include/event_aggregate_load.inc b/mysql-test/suite/perfschema/include/event_aggregate_load.inc index 75069f4b603..4a1b3f02c03 100644 --- a/mysql-test/suite/perfschema/include/event_aggregate_load.inc +++ b/mysql-test/suite/perfschema/include/event_aggregate_load.inc @@ -80,6 +80,12 @@ echo "================== con1 marker =================="; --connection default +# Wait for the payload to complete +let $wait_condition= + select count(*) = 1 from performance_schema.events_waits_current + where EVENT_NAME= 'idle'; +--source include/wait_condition.inc + echo "================== Step 3 =================="; call dump_thread(); execute dump_waits_account; @@ -148,6 +154,12 @@ echo "================== con2 marker =================="; --connection default +# Wait for the payload to complete +let $wait_condition= + select count(*) = 2 from performance_schema.events_waits_current + where EVENT_NAME= 'idle'; +--source include/wait_condition.inc + echo "================== Step 5 =================="; call dump_thread(); execute dump_waits_account; @@ -212,6 +224,12 @@ echo "================== con3 marker =================="; --connection default +# Wait for the payload to complete +let $wait_condition= + select count(*) = 3 from performance_schema.events_waits_current + where EVENT_NAME= 'idle'; +--source include/wait_condition.inc + echo "================== Step 7 =================="; call dump_thread(); execute dump_waits_account; @@ -276,6 +294,12 @@ echo "================== con4 marker =================="; --connection default +# Wait for the payload to complete +let $wait_condition= + select count(*) = 4 from performance_schema.events_waits_current + where EVENT_NAME= 'idle'; +--source include/wait_condition.inc + echo "================== Step 9 =================="; call dump_thread(); execute dump_waits_account; diff --git a/mysql-test/suite/perfschema/include/event_aggregate_setup.inc b/mysql-test/suite/perfschema/include/event_aggregate_setup.inc index 47488403c1f..a0103649c09 100644 --- a/mysql-test/suite/perfschema/include/event_aggregate_setup.inc +++ b/mysql-test/suite/perfschema/include/event_aggregate_setup.inc @@ -111,7 +111,8 @@ update performance_schema.setup_instruments set enabled='YES', timed='YES' where name in ('wait/synch/mutex/sql/LOCK_connection_count', 'wait/synch/mutex/sql/LOCK_user_locks', 'wait/synch/rwlock/sql/LOCK_grant', - 'wait/io/file/sql/query_log'); + 'wait/io/file/sql/query_log', + 'idle'); update performance_schema.setup_instruments set enabled='YES', timed='YES' where name in ('stage/sql/init', diff --git a/mysql-test/suite/perfschema/include/sizing_auto.inc b/mysql-test/suite/perfschema/include/sizing_auto.inc index 61097a1d30d..1a9afeaf219 100644 --- a/mysql-test/suite/perfschema/include/sizing_auto.inc +++ b/mysql-test/suite/perfschema/include/sizing_auto.inc @@ -13,3 +13,4 @@ show status like "%performance_schema%"; # Note that this output is very dependent on the platform. show engine performance_schema status; + diff --git a/mysql-test/suite/perfschema/include/table_aggregate_load.inc b/mysql-test/suite/perfschema/include/table_aggregate_load.inc index b72220c58bd..242768ead9e 100644 --- a/mysql-test/suite/perfschema/include/table_aggregate_load.inc +++ b/mysql-test/suite/perfschema/include/table_aggregate_load.inc @@ -48,17 +48,10 @@ execute dump_objects_summary; # connect (con1, localhost, user1, , ); - -echo "================== con1 connected =================="; +select concat(current_user(), " is connected") as status; --connection default -# Wait for the connect to complete -let $wait_condition= - select count(*) = 1 from performance_schema.threads - where `TYPE`='FOREGROUND' and PROCESSLIST_USER= 'user1'; ---source include/wait_condition.inc - echo "================== Step 2 =================="; call dump_thread(); execute dump_waits_account; @@ -116,17 +109,10 @@ execute dump_objects_summary; # select PROCESSLIST_USER, PROCESSLIST_HOST, INSTRUMENTED from performance_schema.threads; connect (con2, localhost, user2, , ); - -echo "================== con2 connected =================="; +select concat(current_user(), " is connected") as status; --connection default -# Wait for the connect to complete -let $wait_condition= - select count(*) = 1 from performance_schema.threads - where `TYPE`='FOREGROUND' and PROCESSLIST_USER= 'user2'; ---source include/wait_condition.inc - echo "================== Step 4 =================="; call dump_thread(); execute dump_waits_account; @@ -180,17 +166,10 @@ execute dump_waits_table_lock; execute dump_objects_summary; connect (con3, localhost, user3, , ); - -echo "================== con3 connected =================="; +select concat(current_user(), " is connected") as status; --connection default -# Wait for the connect to complete -let $wait_condition= - select count(*) = 1 from performance_schema.threads - where `TYPE`='FOREGROUND' and PROCESSLIST_USER= 'user3'; ---source include/wait_condition.inc - echo "================== Step 6 =================="; call dump_thread(); execute dump_waits_account; @@ -244,17 +223,10 @@ execute dump_waits_table_lock; execute dump_objects_summary; connect (con4, localhost, user4, , ); - -echo "================== con4 connected =================="; +select concat(current_user(), " is connected") as status; --connection default -# Wait for the connect to complete -let $wait_condition= - select count(*) = 1 from performance_schema.threads - where `TYPE`='FOREGROUND' and PROCESSLIST_USER= 'user4'; ---source include/wait_condition.inc - echo "================== Step 8 =================="; call dump_thread(); execute dump_waits_account; |