Bug #37962 *_func tests containing sleeps/race conditions
Submitted: 8 Jul 2008 10:46 Modified: 13 Apr 2009 15:18
Reporter: Sven Sandberg Email Updates:
Status: Closed Impact on me:
None 
Category:Tests: Server Severity:S7 (Test Cases)
Version:5.1+ OS:Any
Assigned to: Horst Hunger CPU Architecture:Any
Tags: delayed_insert_limit_func, disabled, event_scheduler_func, innodb_max_dirty_pages_pct_func, interactive_timeout_func, pushbuild, query_cache_wlock_invalidate_func, race condition, rpl_init_slave_func, rpl_max_binlog_size_func, slow_query_log_func, sql_low_priority_updates_func, test failure, timestamp_func, wait_timeout_func

[8 Jul 2008 10:46] Sven Sandberg
Description:
The following tests contain sleeps, all of which are likely to trigger race conditions:

delayed_insert_limit_func.test
event_scheduler_func.test
innodb_max_dirty_pages_pct_func.test
interactive_timeout_func.test
query_cache_wlock_invalidate_func.test
rpl_init_slave_func.test
rpl_max_binlog_size_func.test
slow_query_log_func.test
sql_low_priority_updates_func.test
timestamp_func.test
wait_timeout_func.test

Disabled all these tests in 5.1-rpl.

How to repeat:
grep sleep mysql-test/t/*_func.test

Suggested fix:
In cases where it is possible, please replace the sleeps by an appropriate 'source include/wait_condition.inc'

In other cases, either:
 - remove the test, or
 - make the threshold at least 30 second and move the test to mysql-test/suite/manual.
[8 Jul 2008 10:52] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/49163

2622 Sven Sandberg	2008-07-08
      BUG#37962: *_func tests containing sleeps/race conditions
      This is not a fix, it just disables the erroneous test cases.
[8 Jul 2008 11:44] Sven Sandberg
Setting back to verified. The pushed changeset only disables the test cases.
[18 Nov 2008 10:55] Matthias Leich
event_scheduler_func has now its own bug:
Bug#40816 event_scheduler_func fails randomly, test does an imperfect cleanup
[18 Nov 2008 10:57] Matthias Leich
event_scheduler_func has now its own bug:
Bug#40816 event_scheduler_func fails randomly, test does an imperfect cleanup
[30 Jan 2009 13:28] Bugs System
Pushed into 6.0.10-alpha (revid:luis.soares@sun.com-20090129165607-wiskabxm948yx463) (version source revid:luis.soares@sun.com-20090129163120-e2ntks4wgpqde6zt) (merge vers: 6.0.10-alpha) (pib:6)
[30 Jan 2009 15:08] Bugs System
Pushed into 5.1.32 (revid:luis.soares@sun.com-20090129165946-d6jnnfqfokuzr09y) (version source revid:mats@mysql.com-20080708162309-ev227w8llwz2sqka) (merge vers: 5.1.28) (pib:6)
[17 Feb 2009 14:57] Bugs System
Pushed into 5.1.32-ndb-6.3.23 (revid:tomas.ulin@sun.com-20090217131017-6u8qz1edkjfiobef) (version source revid:tomas.ulin@sun.com-20090203133556-9rclp06ol19bmzs4) (merge vers: 5.1.32-ndb-6.3.22) (pib:6)
[17 Feb 2009 16:45] Bugs System
Pushed into 5.1.32-ndb-6.4.3 (revid:tomas.ulin@sun.com-20090217134419-5ha6xg4dpedrbmau) (version source revid:tomas.ulin@sun.com-20090203133556-9rclp06ol19bmzs4) (merge vers: 5.1.32-ndb-6.3.22) (pib:6)
[17 Feb 2009 18:21] Bugs System
Pushed into 5.1.32-ndb-6.2.17 (revid:tomas.ulin@sun.com-20090217134216-5699eq74ws4oxa0j) (version source revid:tomas.ulin@sun.com-20090201210519-vehobc4sy3g9s38e) (merge vers: 5.1.32-ndb-6.2.17) (pib:6)
[27 Feb 2009 18:42] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/67904

2825 Horst Hunger	2009-02-27
      Fix for bug#37962: Replace "sleeps" and race conditions. Following tests have been effected.
      
      delayed_insert_limit_func.test:
      Replaced the sleeps, adjusted the tests to have deterministic results when performance is low, beautifications.
      
      event_scheduler_func.test:
      Replaced the sleeps except one sleep that makes sense, beautifications.
      
      innodb_max_dirty_pages_pct_func.test:
      Replaced the sleeps with other fixes.
      
      interactive_timeout_func.test:
      Made the test stable, but as long as CLIENT_INTERACTIVE cannot be set when open a connection the timeout cannot be tested.
      
      query_cache_wlock_invalidate_func.test:
      Replaced the sleeps and added 2 more selects to see that they all will not be blocked.
      
      rpl_init_slave_func.test:
      Replaced the sleeps with other fixes.
      
      rpl_max_binlog_size_func.test:
      Replaced the sleep.
      
      slow_query_log_func.test:
      The sleeps are the long queries and cannot be replaced. Made the test deterministic.
      
      sql_low_priority_updates_func.test:
      Replaced the sleeps.
      
      timestamp_func.test:
      Replaced the sleeps with other fixes.
      
      wait_timeout_func.test:
      Replaced the sleeps with other fixes.
[20 Mar 2009 17:11] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/69941

2816 Horst Hunger	2009-03-20
      Reviewed fix for bug#37962 also including the revised result files for failing system variable tests.
[24 Mar 2009 10:41] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/70168
[27 Mar 2009 14:58] Bugs System
Pushed into 5.1.34 (revid:joro@sun.com-20090327143448-wuuuycetc562ty6o) (version source revid:leonard@mysql.com-20090324071946-no4hie9i1f0kvb7e) (merge vers: 5.1.34) (pib:6)
[27 Mar 2009 15:18] Paul DuBois
Test case changes. No changelog entry needed.

Setting report to NDI pending push into 6.0.x.
[13 Apr 2009 9:22] Bugs System
Pushed into 6.0.11-alpha (revid:alik@sun.com-20090413084402-snnrocwzktcl88ny) (version source revid:horst@mysql.com-20090324104107-vh3w1ohn1ob0j9zp) (merge vers: 6.0.11-alpha) (pib:6)
[13 Apr 2009 15:18] Paul DuBois
Test case changes. No changelog entry needed.
[9 May 2009 16:42] Bugs System
Pushed into 5.1.34-ndb-6.2.18 (revid:jonas@mysql.com-20090508185236-p9b3as7qyauybefl) (version source revid:jonas@mysql.com-20090508185236-p9b3as7qyauybefl) (merge vers: 5.1.34-ndb-6.2.18) (pib:6)
[9 May 2009 17:40] Bugs System
Pushed into 5.1.34-ndb-6.3.25 (revid:jonas@mysql.com-20090509063138-1u3q3v09wnn2txyt) (version source revid:jonas@mysql.com-20090509063138-1u3q3v09wnn2txyt) (merge vers: 5.1.34-ndb-6.3.25) (pib:6)
[9 May 2009 18:37] Bugs System
Pushed into 5.1.34-ndb-7.0.6 (revid:jonas@mysql.com-20090509154927-im9a7g846c6u1hzc) (version source revid:jonas@mysql.com-20090509154927-im9a7g846c6u1hzc) (merge vers: 5.1.34-ndb-7.0.6) (pib:6)