mirror of
https://github.com/MariaDB/server.git
synced 2025-01-30 10:31:54 +01:00
MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
This commit is contained in:
parent
9bd3af97df
commit
9e9ea4f64a
5 changed files with 375 additions and 10 deletions
|
@ -7,9 +7,9 @@ TestNo INT AUTO_INCREMENT PRIMARY KEY,
|
||||||
Source TEXT,
|
Source TEXT,
|
||||||
Target TEXT,
|
Target TEXT,
|
||||||
Flags TEXT,
|
Flags TEXT,
|
||||||
On_Master TEXT,
|
On_Master LONGTEXT,
|
||||||
On_Slave TEXT,
|
On_Slave LONGTEXT,
|
||||||
Expected TEXT,
|
Expected LONGTEXT,
|
||||||
Compare INT,
|
Compare INT,
|
||||||
Error TEXT);
|
Error TEXT);
|
||||||
SELECT @@global.slave_type_conversions;
|
SELECT @@global.slave_type_conversions;
|
||||||
|
@ -39,18 +39,34 @@ ALL_LOSSY,ALL_NON_LOSSY
|
||||||
connection slave;
|
connection slave;
|
||||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS='';
|
SET GLOBAL SLAVE_TYPE_CONVERSIONS='';
|
||||||
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = '' ****
|
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = '' ****
|
||||||
|
#
|
||||||
|
# MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
|
||||||
|
#
|
||||||
|
# End of MDEV-15833
|
||||||
include/rpl_reset.inc
|
include/rpl_reset.inc
|
||||||
connection slave;
|
connection slave;
|
||||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_NON_LOSSY';
|
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_NON_LOSSY';
|
||||||
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_NON_LOSSY' ****
|
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_NON_LOSSY' ****
|
||||||
|
#
|
||||||
|
# MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
|
||||||
|
#
|
||||||
|
# End of MDEV-15833
|
||||||
include/rpl_reset.inc
|
include/rpl_reset.inc
|
||||||
connection slave;
|
connection slave;
|
||||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_LOSSY';
|
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_LOSSY';
|
||||||
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_LOSSY' ****
|
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_LOSSY' ****
|
||||||
|
#
|
||||||
|
# MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
|
||||||
|
#
|
||||||
|
# End of MDEV-15833
|
||||||
include/rpl_reset.inc
|
include/rpl_reset.inc
|
||||||
connection slave;
|
connection slave;
|
||||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_LOSSY,ALL_NON_LOSSY';
|
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_LOSSY,ALL_NON_LOSSY';
|
||||||
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_LOSSY,ALL_NON_LOSSY' ****
|
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_LOSSY,ALL_NON_LOSSY' ****
|
||||||
|
#
|
||||||
|
# MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
|
||||||
|
#
|
||||||
|
# End of MDEV-15833
|
||||||
include/rpl_reset.inc
|
include/rpl_reset.inc
|
||||||
connection slave;
|
connection slave;
|
||||||
**** Result of conversions ****
|
**** Result of conversions ****
|
||||||
|
@ -176,6 +192,26 @@ BIT(5) BIT(6) <Correct error>
|
||||||
BIT(6) BIT(5) <Correct error>
|
BIT(6) BIT(5) <Correct error>
|
||||||
BIT(5) BIT(12) <Correct error>
|
BIT(5) BIT(12) <Correct error>
|
||||||
BIT(12) BIT(5) <Correct error>
|
BIT(12) BIT(5) <Correct error>
|
||||||
|
TINYBLOB COMPRE TINYBLOB <Correct error>
|
||||||
|
TINYBLOB COMPRE BLOB <Correct error>
|
||||||
|
TINYBLOB COMPRE MEDIUMBLOB <Correct error>
|
||||||
|
TINYBLOB COMPRE LONGBLOB <Correct error>
|
||||||
|
TINYBLOB COMPRE VARBINARY(255) <Correct error>
|
||||||
|
BLOB COMPRESSED TINYBLOB <Correct error>
|
||||||
|
BLOB COMPRESSED BLOB <Correct error>
|
||||||
|
BLOB COMPRESSED MEDIUMBLOB <Correct error>
|
||||||
|
BLOB COMPRESSED LONGBLOB <Correct error>
|
||||||
|
BLOB COMPRESSED VARBINARY(65500 <Correct error>
|
||||||
|
MEDIUMBLOB COMP TINYBLOB <Correct error>
|
||||||
|
MEDIUMBLOB COMP BLOB <Correct error>
|
||||||
|
MEDIUMBLOB COMP MEDIUMBLOB <Correct error>
|
||||||
|
MEDIUMBLOB COMP LONGBLOB <Correct error>
|
||||||
|
MEDIUMBLOB COMP VARBINARY(65500 <Correct error>
|
||||||
|
LONGBLOB COMPRE TINYBLOB <Correct error>
|
||||||
|
LONGBLOB COMPRE BLOB <Correct error>
|
||||||
|
LONGBLOB COMPRE MEDIUMBLOB <Correct error>
|
||||||
|
LONGBLOB COMPRE LONGBLOB <Correct error>
|
||||||
|
LONGBLOB COMPRE VARBINARY(65500 <Correct error>
|
||||||
TINYBLOB TINYBLOB ALL_NON_LOSSY <Correct value>
|
TINYBLOB TINYBLOB ALL_NON_LOSSY <Correct value>
|
||||||
TINYBLOB BLOB ALL_NON_LOSSY <Correct value>
|
TINYBLOB BLOB ALL_NON_LOSSY <Correct value>
|
||||||
TINYBLOB MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
TINYBLOB MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
@ -297,6 +333,26 @@ BIT(5) BIT(6) ALL_NON_LOSSY <Correct value>
|
||||||
BIT(6) BIT(5) ALL_NON_LOSSY <Correct error>
|
BIT(6) BIT(5) ALL_NON_LOSSY <Correct error>
|
||||||
BIT(5) BIT(12) ALL_NON_LOSSY <Correct value>
|
BIT(5) BIT(12) ALL_NON_LOSSY <Correct value>
|
||||||
BIT(12) BIT(5) ALL_NON_LOSSY <Correct error>
|
BIT(12) BIT(5) ALL_NON_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE TINYBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE BLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE LONGBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE VARBINARY(255) ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED TINYBLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED BLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED LONGBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED VARBINARY(65500 ALL_NON_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP TINYBLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP BLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP LONGBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP VARBINARY(65500 ALL_NON_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE TINYBLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE BLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE MEDIUMBLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE LONGBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE VARBINARY(65500 ALL_NON_LOSSY <Correct error>
|
||||||
TINYBLOB TINYBLOB ALL_LOSSY <Correct value>
|
TINYBLOB TINYBLOB ALL_LOSSY <Correct value>
|
||||||
TINYBLOB BLOB ALL_LOSSY <Correct error>
|
TINYBLOB BLOB ALL_LOSSY <Correct error>
|
||||||
TINYBLOB MEDIUMBLOB ALL_LOSSY <Correct error>
|
TINYBLOB MEDIUMBLOB ALL_LOSSY <Correct error>
|
||||||
|
@ -418,6 +474,26 @@ BIT(5) BIT(6) ALL_LOSSY <Correct error>
|
||||||
BIT(6) BIT(5) ALL_LOSSY <Correct value>
|
BIT(6) BIT(5) ALL_LOSSY <Correct value>
|
||||||
BIT(5) BIT(12) ALL_LOSSY <Correct error>
|
BIT(5) BIT(12) ALL_LOSSY <Correct error>
|
||||||
BIT(12) BIT(5) ALL_LOSSY <Correct value>
|
BIT(12) BIT(5) ALL_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE TINYBLOB ALL_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE BLOB ALL_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE MEDIUMBLOB ALL_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE LONGBLOB ALL_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE VARBINARY(255) ALL_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED TINYBLOB ALL_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED BLOB ALL_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED MEDIUMBLOB ALL_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED LONGBLOB ALL_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED VARBINARY(65500 ALL_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP TINYBLOB ALL_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP BLOB ALL_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP MEDIUMBLOB ALL_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP LONGBLOB ALL_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP VARBINARY(65500 ALL_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE TINYBLOB ALL_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE BLOB ALL_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE MEDIUMBLOB ALL_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE LONGBLOB ALL_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE VARBINARY(65500 ALL_LOSSY <Correct value>
|
||||||
TINYBLOB TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
TINYBLOB TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
TINYBLOB BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
TINYBLOB BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
TINYBLOB MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
TINYBLOB MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
@ -539,6 +615,26 @@ BIT(5) BIT(6) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
BIT(6) BIT(5) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
BIT(6) BIT(5) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
BIT(5) BIT(12) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
BIT(5) BIT(12) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
BIT(12) BIT(5) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
BIT(12) BIT(5) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE LONGBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE VARBINARY(255) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED LONGBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED VARBINARY(65500 ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP LONGBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP VARBINARY(65500 ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE LONGBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE VARBINARY(65500 ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
DROP TABLE type_conversions;
|
DROP TABLE type_conversions;
|
||||||
call mtr.add_suppression("Slave SQL.*Column 1 of table .test.t1. cannot be converted from type.* error.* 1677");
|
call mtr.add_suppression("Slave SQL.*Column 1 of table .test.t1. cannot be converted from type.* error.* 1677");
|
||||||
connection master;
|
connection master;
|
||||||
|
|
|
@ -14,9 +14,9 @@ CREATE TABLE type_conversions (
|
||||||
Source TEXT,
|
Source TEXT,
|
||||||
Target TEXT,
|
Target TEXT,
|
||||||
Flags TEXT,
|
Flags TEXT,
|
||||||
On_Master TEXT,
|
On_Master LONGTEXT,
|
||||||
On_Slave TEXT,
|
On_Slave LONGTEXT,
|
||||||
Expected TEXT,
|
Expected LONGTEXT,
|
||||||
Compare INT,
|
Compare INT,
|
||||||
Error TEXT);
|
Error TEXT);
|
||||||
|
|
||||||
|
|
|
@ -876,5 +876,175 @@ let $can_convert = $if_is_lossy;
|
||||||
source suite/rpl/include/check_type.inc;
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
# This is to make sure that the compressed data is longer than 64K
|
||||||
|
SET column_compression_threshold=16*256*256;
|
||||||
|
|
||||||
|
# TINYBLOB COMPRESSED
|
||||||
|
|
||||||
|
let $source_type= TINYBLOB COMPRESSED;
|
||||||
|
let $target_type= TINYBLOB;
|
||||||
|
let $source_value= REPEAT('a',250);
|
||||||
|
let $target_value= REPEAT('a',250);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
let $source_type= TINYBLOB COMPRESSED;
|
||||||
|
let $target_type= BLOB;
|
||||||
|
let $source_value= REPEAT('a',250);
|
||||||
|
let $target_value= REPEAT('a',250);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
let $source_type= TINYBLOB COMPRESSED;
|
||||||
|
let $target_type= MEDIUMBLOB;
|
||||||
|
let $source_value= REPEAT('a',250);
|
||||||
|
let $target_value= REPEAT('a',250);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
let $source_type= TINYBLOB COMPRESSED;
|
||||||
|
let $target_type= LONGBLOB;
|
||||||
|
let $source_value= REPEAT('a',250);
|
||||||
|
let $target_value= REPEAT('a',250);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
let $source_type= TINYBLOB COMPRESSED;
|
||||||
|
let $target_type= VARBINARY(255);
|
||||||
|
let $source_value= REPEAT('a',250);
|
||||||
|
let $target_value= REPEAT('a',250);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
|
||||||
|
# BLOB COMPRESSED
|
||||||
|
|
||||||
|
let $source_type= BLOB COMPRESSED;
|
||||||
|
let $target_type= TINYBLOB;
|
||||||
|
let $source_value= REPEAT('a',64000);
|
||||||
|
let $target_value= REPEAT('a',255);
|
||||||
|
let $can_convert = $if_is_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
let $source_type= BLOB COMPRESSED;
|
||||||
|
let $target_type= BLOB;
|
||||||
|
let $source_value= REPEAT('a',64000);
|
||||||
|
let $target_value= REPEAT('a',64000);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
let $source_type= BLOB COMPRESSED;
|
||||||
|
let $target_type= MEDIUMBLOB;
|
||||||
|
let $source_value= REPEAT('a',64000);
|
||||||
|
let $target_value= REPEAT('a',64000);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
let $source_type= BLOB COMPRESSED;
|
||||||
|
let $target_type= LONGBLOB;
|
||||||
|
let $source_value= REPEAT('a',64000);
|
||||||
|
let $target_value= REPEAT('a',64000);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
let $source_type= BLOB COMPRESSED;
|
||||||
|
let $target_type= VARBINARY(65500);
|
||||||
|
let $source_value= REPEAT('a',65500);
|
||||||
|
let $target_value= REPEAT('a',65500);
|
||||||
|
let $can_convert = $if_is_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
|
||||||
|
# MEDIUMBLOB COMPRESSED
|
||||||
|
|
||||||
|
let $source_type= MEDIUMBLOB COMPRESSED;
|
||||||
|
let $target_type= TINYBLOB;
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',255);
|
||||||
|
let $can_convert = $if_is_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
# This failed before the fix
|
||||||
|
let $source_type= MEDIUMBLOB COMPRESSED;
|
||||||
|
let $target_type= BLOB;
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',65535);
|
||||||
|
let $can_convert = $if_is_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
# This failed before the fix
|
||||||
|
let $source_type= MEDIUMBLOB COMPRESSED;
|
||||||
|
let $target_type= MEDIUMBLOB;
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',66000);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
# This failed before the fix
|
||||||
|
let $source_type= MEDIUMBLOB COMPRESSED;
|
||||||
|
let $target_type= LONGBLOB;
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',66000);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
# This failed before the fix
|
||||||
|
let $source_type= MEDIUMBLOB COMPRESSED;
|
||||||
|
let $target_type= VARBINARY(65500);
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',65500);
|
||||||
|
let $can_convert = $if_is_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
|
||||||
|
# LONGBLOB COMPRESSED
|
||||||
|
|
||||||
|
let $source_type= LONGBLOB COMPRESSED;
|
||||||
|
let $target_type= TINYBLOB;
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',255);
|
||||||
|
let $can_convert = $if_is_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
# This failed before the fix
|
||||||
|
let $source_type= LONGBLOB COMPRESSED;
|
||||||
|
let $target_type= BLOB;
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',65535);
|
||||||
|
let $can_convert = $if_is_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
# This failed before the fix
|
||||||
|
let $source_type= LONGBLOB COMPRESSED;
|
||||||
|
let $target_type= MEDIUMBLOB;
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',66000);
|
||||||
|
let $can_convert = $if_is_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
# This failed before the fix
|
||||||
|
let $source_type= LONGBLOB COMPRESSED;
|
||||||
|
let $target_type= LONGBLOB;
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',66000);
|
||||||
|
let $can_convert = $if_is_non_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
# This failed before the fix
|
||||||
|
let $source_type= LONGBLOB COMPRESSED;
|
||||||
|
let $target_type= VARBINARY(65500);
|
||||||
|
let $source_value= REPEAT('a',66000);
|
||||||
|
let $target_value= REPEAT('a',65500);
|
||||||
|
let $can_convert = $if_is_lossy;
|
||||||
|
source suite/rpl/include/check_type.inc;
|
||||||
|
|
||||||
|
SET column_compression_threshold=DEFAULT;
|
||||||
|
--echo # End of MDEV-15833
|
||||||
|
|
||||||
|
|
||||||
--source include/rpl_reset.inc
|
--source include/rpl_reset.inc
|
||||||
enable_query_log;
|
enable_query_log;
|
||||||
|
|
|
@ -7,9 +7,9 @@ TestNo INT AUTO_INCREMENT PRIMARY KEY,
|
||||||
Source TEXT,
|
Source TEXT,
|
||||||
Target TEXT,
|
Target TEXT,
|
||||||
Flags TEXT,
|
Flags TEXT,
|
||||||
On_Master TEXT,
|
On_Master LONGTEXT,
|
||||||
On_Slave TEXT,
|
On_Slave LONGTEXT,
|
||||||
Expected TEXT,
|
Expected LONGTEXT,
|
||||||
Compare INT,
|
Compare INT,
|
||||||
Error TEXT);
|
Error TEXT);
|
||||||
SELECT @@global.slave_type_conversions;
|
SELECT @@global.slave_type_conversions;
|
||||||
|
@ -39,18 +39,34 @@ ALL_LOSSY,ALL_NON_LOSSY
|
||||||
connection slave;
|
connection slave;
|
||||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS='';
|
SET GLOBAL SLAVE_TYPE_CONVERSIONS='';
|
||||||
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = '' ****
|
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = '' ****
|
||||||
|
#
|
||||||
|
# MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
|
||||||
|
#
|
||||||
|
# End of MDEV-15833
|
||||||
include/rpl_reset.inc
|
include/rpl_reset.inc
|
||||||
connection slave;
|
connection slave;
|
||||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_NON_LOSSY';
|
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_NON_LOSSY';
|
||||||
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_NON_LOSSY' ****
|
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_NON_LOSSY' ****
|
||||||
|
#
|
||||||
|
# MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
|
||||||
|
#
|
||||||
|
# End of MDEV-15833
|
||||||
include/rpl_reset.inc
|
include/rpl_reset.inc
|
||||||
connection slave;
|
connection slave;
|
||||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_LOSSY';
|
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_LOSSY';
|
||||||
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_LOSSY' ****
|
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_LOSSY' ****
|
||||||
|
#
|
||||||
|
# MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
|
||||||
|
#
|
||||||
|
# End of MDEV-15833
|
||||||
include/rpl_reset.inc
|
include/rpl_reset.inc
|
||||||
connection slave;
|
connection slave;
|
||||||
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_LOSSY,ALL_NON_LOSSY';
|
SET GLOBAL SLAVE_TYPE_CONVERSIONS='ALL_LOSSY,ALL_NON_LOSSY';
|
||||||
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_LOSSY,ALL_NON_LOSSY' ****
|
**** Running tests with @@SLAVE_TYPE_CONVERSIONS = 'ALL_LOSSY,ALL_NON_LOSSY' ****
|
||||||
|
#
|
||||||
|
# MDEV-15821 Row format replication from LONGBLOB COMPRESSED to LONGBLOB does not work
|
||||||
|
#
|
||||||
|
# End of MDEV-15833
|
||||||
include/rpl_reset.inc
|
include/rpl_reset.inc
|
||||||
connection slave;
|
connection slave;
|
||||||
**** Result of conversions ****
|
**** Result of conversions ****
|
||||||
|
@ -176,6 +192,26 @@ BIT(5) BIT(6) <Correct error>
|
||||||
BIT(6) BIT(5) <Correct error>
|
BIT(6) BIT(5) <Correct error>
|
||||||
BIT(5) BIT(12) <Correct error>
|
BIT(5) BIT(12) <Correct error>
|
||||||
BIT(12) BIT(5) <Correct error>
|
BIT(12) BIT(5) <Correct error>
|
||||||
|
TINYBLOB COMPRE TINYBLOB <Correct error>
|
||||||
|
TINYBLOB COMPRE BLOB <Correct error>
|
||||||
|
TINYBLOB COMPRE MEDIUMBLOB <Correct error>
|
||||||
|
TINYBLOB COMPRE LONGBLOB <Correct error>
|
||||||
|
TINYBLOB COMPRE VARBINARY(255) <Correct error>
|
||||||
|
BLOB COMPRESSED TINYBLOB <Correct error>
|
||||||
|
BLOB COMPRESSED BLOB <Correct error>
|
||||||
|
BLOB COMPRESSED MEDIUMBLOB <Correct error>
|
||||||
|
BLOB COMPRESSED LONGBLOB <Correct error>
|
||||||
|
BLOB COMPRESSED VARBINARY(65500 <Correct error>
|
||||||
|
MEDIUMBLOB COMP TINYBLOB <Correct error>
|
||||||
|
MEDIUMBLOB COMP BLOB <Correct error>
|
||||||
|
MEDIUMBLOB COMP MEDIUMBLOB <Correct error>
|
||||||
|
MEDIUMBLOB COMP LONGBLOB <Correct error>
|
||||||
|
MEDIUMBLOB COMP VARBINARY(65500 <Correct error>
|
||||||
|
LONGBLOB COMPRE TINYBLOB <Correct error>
|
||||||
|
LONGBLOB COMPRE BLOB <Correct error>
|
||||||
|
LONGBLOB COMPRE MEDIUMBLOB <Correct error>
|
||||||
|
LONGBLOB COMPRE LONGBLOB <Correct error>
|
||||||
|
LONGBLOB COMPRE VARBINARY(65500 <Correct error>
|
||||||
TINYBLOB TINYBLOB ALL_NON_LOSSY <Correct value>
|
TINYBLOB TINYBLOB ALL_NON_LOSSY <Correct value>
|
||||||
TINYBLOB BLOB ALL_NON_LOSSY <Correct value>
|
TINYBLOB BLOB ALL_NON_LOSSY <Correct value>
|
||||||
TINYBLOB MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
TINYBLOB MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
@ -297,6 +333,26 @@ BIT(5) BIT(6) ALL_NON_LOSSY <Correct value>
|
||||||
BIT(6) BIT(5) ALL_NON_LOSSY <Correct error>
|
BIT(6) BIT(5) ALL_NON_LOSSY <Correct error>
|
||||||
BIT(5) BIT(12) ALL_NON_LOSSY <Correct value>
|
BIT(5) BIT(12) ALL_NON_LOSSY <Correct value>
|
||||||
BIT(12) BIT(5) ALL_NON_LOSSY <Correct error>
|
BIT(12) BIT(5) ALL_NON_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE TINYBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE BLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE LONGBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE VARBINARY(255) ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED TINYBLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED BLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED LONGBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED VARBINARY(65500 ALL_NON_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP TINYBLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP BLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP MEDIUMBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP LONGBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP VARBINARY(65500 ALL_NON_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE TINYBLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE BLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE MEDIUMBLOB ALL_NON_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE LONGBLOB ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE VARBINARY(65500 ALL_NON_LOSSY <Correct error>
|
||||||
TINYBLOB TINYBLOB ALL_LOSSY <Correct value>
|
TINYBLOB TINYBLOB ALL_LOSSY <Correct value>
|
||||||
TINYBLOB BLOB ALL_LOSSY <Correct error>
|
TINYBLOB BLOB ALL_LOSSY <Correct error>
|
||||||
TINYBLOB MEDIUMBLOB ALL_LOSSY <Correct error>
|
TINYBLOB MEDIUMBLOB ALL_LOSSY <Correct error>
|
||||||
|
@ -418,6 +474,26 @@ BIT(5) BIT(6) ALL_LOSSY <Correct error>
|
||||||
BIT(6) BIT(5) ALL_LOSSY <Correct value>
|
BIT(6) BIT(5) ALL_LOSSY <Correct value>
|
||||||
BIT(5) BIT(12) ALL_LOSSY <Correct error>
|
BIT(5) BIT(12) ALL_LOSSY <Correct error>
|
||||||
BIT(12) BIT(5) ALL_LOSSY <Correct value>
|
BIT(12) BIT(5) ALL_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE TINYBLOB ALL_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE BLOB ALL_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE MEDIUMBLOB ALL_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE LONGBLOB ALL_LOSSY <Correct error>
|
||||||
|
TINYBLOB COMPRE VARBINARY(255) ALL_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED TINYBLOB ALL_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED BLOB ALL_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED MEDIUMBLOB ALL_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED LONGBLOB ALL_LOSSY <Correct error>
|
||||||
|
BLOB COMPRESSED VARBINARY(65500 ALL_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP TINYBLOB ALL_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP BLOB ALL_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP MEDIUMBLOB ALL_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP LONGBLOB ALL_LOSSY <Correct error>
|
||||||
|
MEDIUMBLOB COMP VARBINARY(65500 ALL_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE TINYBLOB ALL_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE BLOB ALL_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE MEDIUMBLOB ALL_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE LONGBLOB ALL_LOSSY <Correct error>
|
||||||
|
LONGBLOB COMPRE VARBINARY(65500 ALL_LOSSY <Correct value>
|
||||||
TINYBLOB TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
TINYBLOB TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
TINYBLOB BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
TINYBLOB BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
TINYBLOB MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
TINYBLOB MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
@ -539,6 +615,26 @@ BIT(5) BIT(6) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
BIT(6) BIT(5) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
BIT(6) BIT(5) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
BIT(5) BIT(12) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
BIT(5) BIT(12) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
BIT(12) BIT(5) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
BIT(12) BIT(5) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE LONGBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
TINYBLOB COMPRE VARBINARY(255) ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED LONGBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
BLOB COMPRESSED VARBINARY(65500 ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP LONGBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
MEDIUMBLOB COMP VARBINARY(65500 ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE TINYBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE BLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE MEDIUMBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE LONGBLOB ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
|
LONGBLOB COMPRE VARBINARY(65500 ALL_LOSSY,ALL_NON_LOSSY <Correct value>
|
||||||
DROP TABLE type_conversions;
|
DROP TABLE type_conversions;
|
||||||
call mtr.add_suppression("Slave SQL.*Column 1 of table .test.t1. cannot be converted from type.* error.* 1677");
|
call mtr.add_suppression("Slave SQL.*Column 1 of table .test.t1. cannot be converted from type.* error.* 1677");
|
||||||
connection master;
|
connection master;
|
||||||
|
|
|
@ -1392,10 +1392,13 @@ Field *Type_handler_blob_compressed::make_conversion_table_field(TABLE *table,
|
||||||
const Field *target)
|
const Field *target)
|
||||||
const
|
const
|
||||||
{
|
{
|
||||||
|
uint pack_length= metadata & 0x00ff;
|
||||||
|
if (pack_length < 1 || pack_length > 4)
|
||||||
|
return NULL; // Broken binary log?
|
||||||
return new(table->in_use->mem_root)
|
return new(table->in_use->mem_root)
|
||||||
Field_blob_compressed(NULL, (uchar *) "", 1, Field::NONE,
|
Field_blob_compressed(NULL, (uchar *) "", 1, Field::NONE,
|
||||||
&empty_clex_str,
|
&empty_clex_str,
|
||||||
table->s, 2, target->charset(),
|
table->s, pack_length, target->charset(),
|
||||||
zlib_compression_method);
|
zlib_compression_method);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue