From e69e640f2eedfe1247f2a5f536d8dc1cf8a48300 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 17 Jul 2006 16:52:45 +0200 Subject: WL#3337 (Events new architecture) Small updates before patch submit. client/mysqltest.c: allow --valgrind option to mysqltest so one can be able to detect whether the test is running under valgrind by having $VALGRIND_TEST, similar to BIG_TEST, in the test file. mysql-test/mysql-test-run.pl: If the test suite is running under valgrind start mysqltest with --valgrind to inform that we run valgrind. mysqltest will provide $VALGRIND_TEST for the test cases. mysql-test/r/events_bugs.result: update result mysql-test/r/events_scheduling.result: update result mysql-test/t/events.test: Increase times or the test will fail under valgrind mysql-test/t/events_bugs.test: Increase times or the test will fail under valgrind mysql-test/t/events_scheduling.test: Remove faulty test Disable the test case for valgrind sql/event_data_objects.cc: count the number of executions sql/event_data_objects.h: flags is not used at all add execution_count to count the number of executions sql/event_db_repository.cc: Initialize wherever needed. Add a comment regarding valgrind warning. sql/event_queue.cc: more debug info in the trace log sql/event_scheduler.cc: Use macro COND_STATE_WAIT() in all cases we need waiting on condition. Hence, we can trace locking, attemption to lock and more with SHOW SCHEDULER STATUS sql/event_scheduler.h: Change the declaration of cond_wait to accept THD sql/events.cc: fix memory leak. Destroy event_queue mysql-test/include/not_valgrind.inc: New BitKeeper file ``mysql-test/include/not_valgrind.inc'' mysql-test/r/not_valgrind.require: New BitKeeper file ``mysql-test/r/not_valgrind.require'' --- mysql-test/t/events_bugs.test | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'mysql-test/t/events_bugs.test') diff --git a/mysql-test/t/events_bugs.test b/mysql-test/t/events_bugs.test index 7fd4c684b4b..692e85255ef 100644 --- a/mysql-test/t/events_bugs.test +++ b/mysql-test/t/events_bugs.test @@ -78,9 +78,9 @@ begin drop table "hashed_num"; end| delimiter ;| ---sleep 0.5 +--sleep 0.8 --echo "Now if everything is fine the event has compiled and is locked -select /*1*/ user, host, db, command, state, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; +select /*1*/ user, host, db, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; select release_lock('test_bug16407'); set global event_scheduler= 2; @@ -127,11 +127,11 @@ begin end| delimiter ;| select event_schema, event_name, sql_mode from information_schema.events order by event_schema, event_name; ---sleep 0.5 -select /*2*/ user, host, db, command, state, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; +--sleep 1 +select /*2*/ user, host, db, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; select release_lock('ee_16407_2'); ---sleep 0.8 -select /*3*/ user, host, db, command, state, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; +--sleep 1.2 +select /*3*/ user, host, db, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; set global event_scheduler= 2; select * from events_smode_test order by ev_name, a; --echo "OK, last check before we drop them" @@ -165,13 +165,13 @@ begin call events_test.ee_16407_6_pendant(); end| delimiter ;| ---sleep 0.5 +--sleep 1 --echo "Should have 2 locked processes" -select /*4*/ user, host, db, command, state, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; +select /*4*/ user, host, db, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; select release_lock('ee_16407_5'); ---sleep 0.8 +--sleep 1.3 --echo "Should have 0 processes locked" -select /*5*/ user, host, db, command, state, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; +select /*5*/ user, host, db, info from information_schema.processlist where info is null or info not like '%processlist%' order by info; select * from events_smode_test order by ev_name, a; --echo "And here we check one more time before we drop the events" select event_schema, event_name, sql_mode from information_schema.events order by event_schema, event_name; -- cgit v1.2.1