Merge branch '3.0' into PT-139

This commit is contained in:
Carlos Salguero
2017-05-22 14:13:42 -03:00
20 changed files with 28 additions and 23 deletions

View File

@@ -45,7 +45,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -43,7 +43,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -42,7 +42,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -38,7 +38,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -39,7 +39,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -35,7 +35,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -37,7 +37,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -44,7 +44,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -45,7 +45,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -47,7 +47,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -55,7 +55,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';
@@ -10073,7 +10073,12 @@ sub find_renamed_cols {
/x; /x;
my $table_ident = qr/$unquoted_ident|`$quoted_ident`|"$ansi_quotes_ident"/; my $table_ident = qr/$unquoted_ident|`$quoted_ident`|"$ansi_quotes_ident"/;
my $alter_change_col_re = qr/\bCHANGE \s+ (?:COLUMN \s+)? (?:COMMENT\s+[^\]['"].*?[^\]['"])?
# remove comments
$alter =~ s/^(.*?)\s+COMMENT\s+'(.*?[^\\]')+(.*)/$1$3/;
$alter =~ s/^(.*?)\s+COMMENT\s+"(.*?[^\\]")+(.*)/$1$3/;
my $alter_change_col_re = qr/\bCHANGE \s+ (?:COLUMN \s+)?
($table_ident) \s+ ($table_ident)/ix; ($table_ident) \s+ ($table_ident)/ix;
my %renames; my %renames;

View File

@@ -64,7 +64,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -40,7 +40,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -41,7 +41,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -57,7 +57,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -55,7 +55,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -61,7 +61,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -44,7 +44,7 @@ BEGIN {
{ {
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -18,7 +18,7 @@
# ########################################################################### # ###########################################################################
package Percona::Toolkit; package Percona::Toolkit;
our $VERSION = '3.0.2'; our $VERSION = '3.0.3';
use strict; use strict;
use warnings FATAL => 'all'; use warnings FATAL => 'all';

View File

@@ -610,7 +610,7 @@ $sb->load_file('master', "$sample/bug-1613915.sql");
$output = output( $output = output(
sub { pt_online_schema_change::main(@args, "$master_dsn,D=test,t=o1", sub { pt_online_schema_change::main(@args, "$master_dsn,D=test,t=o1",
'--execute', '--execute',
'--alter', "ADD COLUMN c INT COMMENT 'change plus more than one word'", '--alter', "ADD COLUMN c INT COMMENT 'change \"plus\" more than one word'",
'--chunk-size', '10', '--no-check-alter', '--chunk-size', '10', '--no-check-alter',
), ),
}, },
@@ -633,7 +633,7 @@ is(
$rows = $master_dbh->selectrow_arrayref("SHOW CREATE TABLE test.o1"); $rows = $master_dbh->selectrow_arrayref("SHOW CREATE TABLE test.o1");
like( like(
$rows->[1], $rows->[1],
qr/COMMENT 'change plus more than one word'/, qr/COMMENT 'change "plus" more than one word'/,
"recognize comments", "recognize comments",
); );