~percona-dev/percona-server/5.1.57-fix_bug_785564

« back to all changes in this revision

Viewing changes to innodb_expand_import.patch

  • Committer: Oleg Tsarev
  • Date: 2010-12-14 20:03:02 UTC
  • mfrom: (169 release-5.1.53-tmp)
  • mto: This revision was merged to the branch mainline in revision 171.
  • Revision ID: oleg.tsarev@percona.com-20101214200302-hmulr329e352xhaw
add --without-response_time_distribution

Show diffs side-by-side

added added

removed removed

Lines of Context:
498
498
diff -ruN a/storage/innodb_plugin/handler/ha_innodb.cc b/storage/innodb_plugin/handler/ha_innodb.cc
499
499
--- a/storage/innodb_plugin/handler/ha_innodb.cc        2010-04-29 16:54:08.000000000 +0900
500
500
+++ b/storage/innodb_plugin/handler/ha_innodb.cc        2010-04-30 10:28:05.000000000 +0900
501
 
@@ -11305,6 +11305,11 @@
 
501
@@ -7109,6 +7109,14 @@
 
502
                err = row_discard_tablespace_for_mysql(dict_table->name, trx);
 
503
        } else {
 
504
                err = row_import_tablespace_for_mysql(dict_table->name, trx);
 
505
+
 
506
+               /* in expanded import mode re-initialize auto_increment again */
 
507
+               if ((err == DB_SUCCESS) && srv_expand_import &&
 
508
+                   (table->found_next_number_field != NULL)) {
 
509
+                       dict_table_autoinc_lock(dict_table);
 
510
+                       innobase_initialize_autoinc();
 
511
+                       dict_table_autoinc_unlock(dict_table);
 
512
+               }
 
513
        }
 
514
 
 
515
        err = convert_error_code_to_mysql(err, dict_table->flags, NULL);
 
516
@@ -11305,6 +11313,11 @@
502
517
   "Enable/Disable unsafe group commit when support_xa=OFF and use with binlog or other XA storage engine.",
503
518
   NULL, NULL, 0, 0, 1, 0);
504
519
 
510
525
 static MYSQL_SYSVAR_ULONG(extra_rsegments, srv_extra_rsegments,
511
526
   PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY,
512
527
   "Number of extra user rollback segments when create new database.",
513
 
@@ -11381,6 +11386,7 @@
 
528
@@ -11381,6 +11394,7 @@
514
529
   MYSQL_SYSVAR(adaptive_checkpoint),
515
530
   MYSQL_SYSVAR(flush_log_at_trx_commit_session),
516
531
   MYSQL_SYSVAR(enable_unsafe_group_commit),