List:Commits« Previous MessageNext Message »
From:Mattias Jonsson Date:May 16 2012 10:48am
Subject:bzr push into mysql-trunk branch (mattias.jonsson:3831 to 3833)
View as plain text  
 3833 Mattias Jonsson	2012-05-16
      WL4443:
      fixed test to work on non default innodb-page-size
      removed unused variable.

    modified:
      mysql-test/suite/parts/r/partition_debug_sync_innodb.result
      mysql-test/suite/parts/t/partition_debug_sync_innodb.test
      sql/sql_partition_admin.cc
 3832 Mattias Jonsson	2012-05-16
      WL4443:
      Updated DBUG_ASSERT in
      open_normal_and_derived_tables
      to better work with stored procedures without
      prelocking.

    modified:
      sql/sql_base.cc
 3831 Mattias Jonsson	2012-05-16
      WL#4443:
      Added check of trigger columns vs
      partitioning columns to see if possible to do
      lock pruning.
      
      TODO: Fix multi update with triggers on two tables.

    modified:
      mysql-test/collections/mysql-trunk-wl4443.push
      mysql-test/r/partition_locking.result
      mysql-test/t/partition_locking.test
      sql/partition_info.cc
      sql/sql_trigger.cc
      sql/sql_trigger.h
      sql/sql_update.cc
=== modified file 'mysql-test/suite/parts/r/partition_debug_sync_innodb.result'
--- a/mysql-test/suite/parts/r/partition_debug_sync_innodb.result	revid:mattias.jonsson@stripped
+++ b/mysql-test/suite/parts/r/partition_debug_sync_innodb.result	revid:mattias.jonsson@stripped
@@ -58,7 +58,10 @@ t1.frm
 t1.par
 SET DEBUG_SYNC='before_open_in_get_all_tables SIGNAL parked WAIT_FOR open';
 SET DEBUG_SYNC='partition_open_error SIGNAL alter WAIT_FOR finish';
-SELECT * FROM INFORMATION_SCHEMA.PARTITIONS WHERE TABLE_NAME = 't1' AND TABLE_SCHEMA = 'test';
+SELECT TABLE_SCHEMA, TABLE_NAME, PARTITION_NAME, PARTITION_ORDINAL_POSITION,
+PARTITION_DESCRIPTION, TABLE_ROWS
+FROM INFORMATION_SCHEMA.PARTITIONS
+WHERE TABLE_NAME = 't1' AND TABLE_SCHEMA = 'test';
 SET DEBUG_SYNC = 'now WAIT_FOR parked';
 # When waiting for the name lock in get_all_tables in sql_show.cc
 # this will not be concurrent any more, thus the TIMEOUT
@@ -70,9 +73,9 @@ ALTER TABLE t1 REORGANIZE PARTITION p0 I
 PARTITION p10 VALUES LESS THAN MAXVALUE);
 Warnings:
 Warning	1639	debug sync point wait timed out
-TABLE_CATALOG	TABLE_SCHEMA	TABLE_NAME	PARTITION_NAME	SUBPARTITION_NAME	PARTITION_ORDINAL_POSITION	SUBPARTITION_ORDINAL_POSITION	PARTITION_METHOD	SUBPARTITION_METHOD	PARTITION_EXPRESSION	SUBPARTITION_EXPRESSION	PARTITION_DESCRIPTION	TABLE_ROWS	AVG_ROW_LENGTH	DATA_LENGTH	MAX_DATA_LENGTH	INDEX_LENGTH	DATA_FREE	CREATE_TIME	UPDATE_TIME	CHECK_TIME	CHECKSUM	PARTITION_COMMENT	NODEGROUP	TABLESPACE_NAME
-def	test	t1	p0	NULL	1	NULL	RANGE	NULL	a	NULL	10	1	16384	16384	NULL	0	0	NULL	NULL	NULL	NULL		default	NULL
-def	test	t1	p10	NULL	2	NULL	RANGE	NULL	a	NULL	MAXVALUE	3	5461	16384	NULL	0	0	NULL	NULL	NULL	NULL		default	NULL
+TABLE_SCHEMA	TABLE_NAME	PARTITION_NAME	PARTITION_ORDINAL_POSITION	PARTITION_DESCRIPTION	TABLE_ROWS
+test	t1	p0	1	10	1
+test	t1	p10	2	MAXVALUE	3
 t1#P#p0.ibd
 t1#P#p10.ibd
 t1.frm

=== modified file 'mysql-test/suite/parts/t/partition_debug_sync_innodb.test'
--- a/mysql-test/suite/parts/t/partition_debug_sync_innodb.test	revid:mattias.jonsson@stripped
+++ b/mysql-test/suite/parts/t/partition_debug_sync_innodb.test	revid:mattias.jonsson@stripped
@@ -62,7 +62,10 @@ SHOW CREATE TABLE t1;
 SET DEBUG_SYNC='before_open_in_get_all_tables SIGNAL parked WAIT_FOR open';
 SET DEBUG_SYNC='partition_open_error SIGNAL alter WAIT_FOR finish';
 send
-SELECT * FROM INFORMATION_SCHEMA.PARTITIONS WHERE TABLE_NAME = 't1' AND TABLE_SCHEMA = 'test';
+SELECT TABLE_SCHEMA, TABLE_NAME, PARTITION_NAME, PARTITION_ORDINAL_POSITION,
+       PARTITION_DESCRIPTION, TABLE_ROWS
+FROM INFORMATION_SCHEMA.PARTITIONS
+WHERE TABLE_NAME = 't1' AND TABLE_SCHEMA = 'test';
 
 connect (con1, localhost, root,,);
 SET DEBUG_SYNC = 'now WAIT_FOR parked';

=== modified file 'sql/sql_base.cc'
--- a/sql/sql_base.cc	revid:mattias.jonsson@stripped
+++ b/sql/sql_base.cc	revid:mattias.jonsson@stripped
@@ -5744,8 +5744,7 @@ end:
   */
   DBUG_ASSERT(thd->transaction.stmt.is_empty() ||
               (thd->state_flags & Open_tables_state::BACKUPS_AVAIL) ||
-              (thd->stmt_arena->state ==
-                                  Query_arena::STMT_INITIALIZED_FOR_SP));
+              thd->in_sub_stmt);
   close_thread_tables(thd);
   /* Don't keep locks for a failed statement. */
   thd->mdl_context.rollback_to_savepoint(mdl_savepoint);

=== modified file 'sql/sql_partition_admin.cc'
--- a/sql/sql_partition_admin.cc	revid:mattias.jonsson@stripped
+++ b/sql/sql_partition_admin.cc	revid:mattias.jonsson@stripped
@@ -498,7 +498,6 @@ bool Sql_cmd_alter_table_exchange_partit
   MDL_ticket *swap_table_mdl_ticket= NULL;
   MDL_ticket *part_table_mdl_ticket= NULL;
   uint table_counter;
-  MDL_savepoint mdl_savepoint= thd->mdl_context.mdl_savepoint();
   bool error= TRUE;
   DBUG_ENTER("mysql_exchange_partition");
   DBUG_ASSERT(alter_info->flags & Alter_info::ALTER_EXCHANGE_PARTITION);

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-trunk branch (mattias.jonsson:3831 to 3833) Mattias Jonsson16 May