MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Rafal Somla Date:July 9 2008 1:37pm
Subject:bzr commit into mysql-6.0-backup branch (rsomla:2655) Bug#3799
View as plain text  
#At file:///ext/mysql/bzr/mysql-6.0-backup-merge-1/

 2655 Rafal Somla	2008-07-09
      BUG#3799 (backup_commit_blocker test hangs):
      
      The problem is that SELECTing from INFORMATION_SCHEMA.PROCESSLIST (to show state
      of the threads) is not realiable and hangs sometimes.
      
      This patch comments-out selects from INFORMATION_SCHEMA.PROCESSLIST as they
      are not essential for the test.
modified:
  mysql-test/r/backup_commit_blocker.result
  mysql-test/t/backup_commit_blocker.test

=== modified file 'mysql-test/r/backup_commit_blocker.result'
--- a/mysql-test/r/backup_commit_blocker.result	2008-07-02 11:00:33 +0000
+++ b/mysql-test/r/backup_commit_blocker.result	2008-07-09 13:37:03 +0000
@@ -66,11 +66,6 @@ con1: Backing up database -- will block 
 BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak";
 con5: Wait for BACKUP to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR bup_commit_block';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
-state	info
-debug sync point: before_commit_block	BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak"
 con3: Activate synchronization points for COMMIT.
 SET DEBUG_SYNC= 'within_ha_commit_trans SIGNAL commit_read_locked
                  WAIT_FOR commit_go_done';
@@ -79,32 +74,12 @@ con3: Starting commit -- will block on s
 COMMIT;
 con5: Wait for COMMIT to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR commit_read_locked';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "COMMIT%";
-state	info
-debug sync point: within_ha_commit_trans	COMMIT
 con5: Let BACKUP run until the next sync point.
 SET DEBUG_SYNC= 'now SIGNAL bup_go_read_lock WAIT_FOR bup_read_lock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
-state	info
-Waiting to get readlock	BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak"
 con5: Let COMMIT continue until end of statement.
 con5: The completed COMMIT implicitly wakes BACKUP.
 con5: So wait for BACKUP to reach the next synchronization point.
 SET DEBUG_SYNC= 'now SIGNAL commit_go_done WAIT_FOR bup_read_locked';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "COMMIT%";
-state	info
-debug sync point: after_commit	COMMIT
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
-state	info
-debug sync point: before_backup_unblock_commit	BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak"
 con4: Activate synchronization point for BEGIN.
 SET DEBUG_SYNC= 'before_begin_trans SIGNAL begin_starting
                  WAIT_FOR finish';
@@ -113,11 +88,6 @@ Assumption (c): TRX not started is not i
 BEGIN;
 con5: Wait for BEGIN to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR begin_starting';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BEGIN%";
-state	info
-debug sync point: before_begin_trans	BEGIN
 con5: Sending finish signal to wake them all.
 SET DEBUG_SYNC= 'now SIGNAL finish';
 con2: Completing transaction
@@ -227,11 +197,6 @@ con1: Backing up database -- will block 
 BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak";
 con5: Wait for BACKUP to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR bup_data_unlock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
-state	info
-debug sync point: before_backup_data_unlock	BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak"
 con7: Show that the statement in progress has executed before backup.
 SELECT * FROM bup_commit_blocker.t5;
 col_a
@@ -247,11 +212,6 @@ Assumption (e): non-TRX not started is n
 UPDATE bup_commit_blocker.t5 SET col_a = 333 WHERE col_a = 30;
 con5: Wait for UPDATE to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR upd_read_lock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "UPDATE%";
-state	info
-Waiting for release of readlock	UPDATE bup_commit_blocker.t5 SET col_a = 333 WHERE col_a = 30
 con5: Sending finish signal to wake them all.
 SET DEBUG_SYNC= 'now SIGNAL finish';
 con7: Fetch UPDATE result
@@ -365,11 +325,6 @@ con1: Backing up database -- will block 
 BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak";
 con5: Wait for BACKUP to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR bup_commit_block';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
-state	info
-debug sync point: before_commit_block	BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak"
 con3: Activate synchronization points for COMMIT.
 SET DEBUG_SYNC= 'within_ha_commit_trans SIGNAL commit_read_locked
                  WAIT_FOR commit_go_done';
@@ -378,32 +333,12 @@ con3: Starting commit -- will block on s
 COMMIT;
 con5: Wait for COMMIT to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR commit_read_locked';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "COMMIT%";
-state	info
-debug sync point: within_ha_commit_trans	COMMIT
 con5: Let BACKUP run until the next sync point.
 SET DEBUG_SYNC= 'now SIGNAL bup_go_read_lock WAIT_FOR bup_read_lock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
-state	info
-Waiting to get readlock	BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak"
 con5: Let COMMIT continue until the sync point at its end.
 con5: The completed COMMIT implicitly wakes BACKUP.
 con5: So wait for BACKUP to reach the next synchronization point.
 SET DEBUG_SYNC= 'now SIGNAL commit_go_done WAIT_FOR bup_read_locked';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "COMMIT%";
-state	info
-debug sync point: after_commit	COMMIT
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
-state	info
-debug sync point: before_backup_unblock_commit	BACKUP DATABASE bup_commit_blocker TO "bup_commit_blocker.bak"
 con4: Activate synchronization point for BEGIN.
 SET DEBUG_SYNC= 'before_begin_trans SIGNAL begin_starting
                  WAIT_FOR finish';
@@ -412,11 +347,6 @@ Assumption (c): TRX not started is not i
 BEGIN;
 con5: Wait for BEGIN to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR begin_starting';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BEGIN%";
-state	info
-debug sync point: before_begin_trans	BEGIN
 con7: Show that the statement in progress has executed before backup.
 SELECT * FROM bup_commit_blocker.t5;
 col_a
@@ -432,11 +362,6 @@ Assumption (e): non-TRX not started is n
 DELETE FROM bup_commit_blocker.t5 WHERE col_a = 50;
 con5: Wait for DELETE to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR del_read_lock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "DELETE%";
-state	info
-Waiting for release of readlock	DELETE FROM bup_commit_blocker.t5 WHERE col_a = 50
 con5: Sending finish signal to wake them all.
 SET DEBUG_SYNC= 'now SIGNAL finish';
 con2: Completing transaction

=== modified file 'mysql-test/t/backup_commit_blocker.test'
--- a/mysql-test/t/backup_commit_blocker.test	2008-07-02 11:00:33 +0000
+++ b/mysql-test/t/backup_commit_blocker.test	2008-07-09 13:37:03 +0000
@@ -61,6 +61,15 @@ connect (con5,localhost,root,,);
 connect (con6,localhost,root,,);
 connect (con7,localhost,root,,);
 
+#
+# Note: Originally we used SELECT ... FROM INFORMATION_SCHEMA.PROCESSLIST; to show status of 
+# the various connections participating in the test. But INFORMATION_SCHEMA.PROCESSLIST implementation
+# proved to be not relaiable. From time to time (nondeterminisrtically) test hanged on these SELECTs.
+# As showing the status is not essential for the test (we test correctness by checking the contents of
+# the created backup image), the selects are commented out now. They can be re-enabled when
+# I_S.PROCESSLIST is in a better shape.
+#
+
 connection con1;
 
 #
@@ -182,9 +191,9 @@ connection con5;
 
 --echo con5: Wait for BACKUP to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR bup_commit_block';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "BACKUP DATABASE%";
 
 connection con3;
 
@@ -199,26 +208,26 @@ connection con5;
 
 --echo con5: Wait for COMMIT to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR commit_read_locked';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "COMMIT%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "COMMIT%";
 
 --echo con5: Let BACKUP run until the next sync point.
 SET DEBUG_SYNC= 'now SIGNAL bup_go_read_lock WAIT_FOR bup_read_lock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "BACKUP DATABASE%";
 
 --echo con5: Let COMMIT continue until end of statement.
 --echo con5: The completed COMMIT implicitly wakes BACKUP.
 --echo con5: So wait for BACKUP to reach the next synchronization point.
 SET DEBUG_SYNC= 'now SIGNAL commit_go_done WAIT_FOR bup_read_locked';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "COMMIT%";
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "COMMIT%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "BACKUP DATABASE%";
 
 connection con4;
 
@@ -233,9 +242,9 @@ connection con5;
 
 --echo con5: Wait for BEGIN to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR begin_starting';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BEGIN%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "BEGIN%";
 
 --echo con5: Sending finish signal to wake them all.
 SET DEBUG_SYNC= 'now SIGNAL finish';
@@ -390,9 +399,9 @@ connection con5;
 
 --echo con5: Wait for BACKUP to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR bup_data_unlock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "BACKUP DATABASE%";
 
 connection con7;
 
@@ -410,9 +419,9 @@ connection con5;
 
 --echo con5: Wait for UPDATE to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR upd_read_lock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "UPDATE%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "UPDATE%";
 
 --echo con5: Sending finish signal to wake them all.
 SET DEBUG_SYNC= 'now SIGNAL finish';
@@ -614,9 +623,9 @@ connection con5;
 
 --echo con5: Wait for BACKUP to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR bup_commit_block';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "BACKUP DATABASE%";
 
 #--echo con5: Wait for INSERT to reach its synchronization point.
 #SET DEBUG_SYNC= 'now WAIT_FOR insert_table_locked';
@@ -637,26 +646,26 @@ connection con5;
 
 --echo con5: Wait for COMMIT to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR commit_read_locked';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "COMMIT%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "COMMIT%";
 
 --echo con5: Let BACKUP run until the next sync point.
 SET DEBUG_SYNC= 'now SIGNAL bup_go_read_lock WAIT_FOR bup_read_lock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "BACKUP DATABASE%";
 
 --echo con5: Let COMMIT continue until the sync point at its end.
 --echo con5: The completed COMMIT implicitly wakes BACKUP.
 --echo con5: So wait for BACKUP to reach the next synchronization point.
 SET DEBUG_SYNC= 'now SIGNAL commit_go_done WAIT_FOR bup_read_locked';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "COMMIT%";
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BACKUP DATABASE%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "COMMIT%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "BACKUP DATABASE%";
 
 connection con4;
 
@@ -671,9 +680,9 @@ connection con5;
 
 --echo con5: Wait for BEGIN to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR begin_starting';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "BEGIN%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "BEGIN%";
 
 connection con7;
 
@@ -691,9 +700,9 @@ connection con5;
 
 --echo con5: Wait for DELETE to reach its synchronization point.
 SET DEBUG_SYNC= 'now WAIT_FOR del_read_lock';
-SELECT state, info FROM
-INFORMATION_SCHEMA.PROCESSLIST
-WHERE info LIKE "DELETE%";
+#SELECT state, info FROM
+#INFORMATION_SCHEMA.PROCESSLIST
+#WHERE info LIKE "DELETE%";
 
 --echo con5: Sending finish signal to wake them all.
 SET DEBUG_SYNC= 'now SIGNAL finish';

Thread
bzr commit into mysql-6.0-backup branch (rsomla:2655) Bug#3799Rafal Somla9 Jul
  • Re: bzr commit into mysql-6.0-backup branch (rsomla:2655) Bug#3799Ingo Strüwing9 Jul
  • RE: bzr commit into mysql-6.0-backup branch (rsomla:2655) Bug#3799Chuck Bell9 Jul