From dd9a5dd5b5d1234dcbb3bd2edef7bad7d2589dfb Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Sat, 19 Oct 2024 14:19:57 +0200 Subject: [PATCH] MDEV-35204 mysqlbinlog --verbose fails on row events with vector type test case --- mysql-test/suite/rpl/r/vector.result | 43 ++++++++++++++++++++++++++++ mysql-test/suite/rpl/t/vector.test | 8 ++++++ 2 files changed, 51 insertions(+) diff --git a/mysql-test/suite/rpl/r/vector.result b/mysql-test/suite/rpl/r/vector.result index 682bbf7fef8..a1ec9908ce5 100644 --- a/mysql-test/suite/rpl/r/vector.result +++ b/mysql-test/suite/rpl/r/vector.result @@ -11,4 +11,47 @@ pk vec_totext(a) 1 [0] connection master; drop table t; +# +# MDEV-35204 mysqlbinlog --verbose fails on row events with vector type +# +flush binary logs; +/*!50530 SET @@SESSION.PSEUDO_SLAVE_MODE=1*/; +/*!40019 SET @@session.max_delayed_threads=0*/; +/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/; +DELIMITER /*!*/; +ROLLBACK/*!*/; +/*M!100101 SET @@session.skip_parallel_replication=0*//*!*/; +/*M!100001 SET @@session.gtid_domain_id=0*//*!*/; +/*M!100001 SET @@session.server_id=1*//*!*/; +/*M!100001 SET @@session.gtid_seq_no=1*//*!*/; +use `test`/*!*/; +SET @@session.pseudo_thread_id=123/*!*/; +SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1, @@session.check_constraint_checks=1, @@session.sql_if_exists=0, @@session.explicit_defaults_for_timestamp=1, @@session.system_versioning_insert_history=0/*!*/; +SET @@session.sql_mode=1411383296/*!*/; +SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/; +/*!\C latin1 *//*!*/; +SET @@session.character_set_client=latin1,@@session.collation_connection=8,@@session.collation_server=2304/*!*/; +SET @@session.lc_time_names=0/*!*/; +SET @@session.collation_database=DEFAULT/*!*/; +create table t (pk int primary key, a vector(1) not null) +/*!*/; +/*M!100001 SET @@session.gtid_seq_no=2*//*!*/; +START TRANSACTION +/*!*/; +#Q> insert into t values (1, 0x00000000) +### INSERT INTO `test`.`t` +### SET +### @1=1 +### @2='\x00\x00\x00\x00' +# Number of rows: 1 +COMMIT +/*!*/; +/*M!100001 SET @@session.gtid_seq_no=3*//*!*/; +DROP TABLE `t` /* generated by server */ +/*!*/; +DELIMITER ; +# End of log file +ROLLBACK /* added by mysqlbinlog */; +/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/; +/*!50530 SET @@SESSION.PSEUDO_SLAVE_MODE=0*/; include/rpl_end.inc diff --git a/mysql-test/suite/rpl/t/vector.test b/mysql-test/suite/rpl/t/vector.test index 8d7bd16b250..1f368f57997 100644 --- a/mysql-test/suite/rpl/t/vector.test +++ b/mysql-test/suite/rpl/t/vector.test @@ -13,4 +13,12 @@ select pk, vec_totext(a) from t; --connection master drop table t; +--echo # +--echo # MDEV-35204 mysqlbinlog --verbose fails on row events with vector type +--echo # +flush binary logs; +--let $datadir= `select @@datadir` +--replace_regex /#\d.*\n// /SET TIMESTAMP=\d+.*\n// /pseudo_thread_id=\d+/pseudo_thread_id=123/ +--exec $MYSQL_BINLOG --verbose --base64-output=never --skip-print-row-event-positions $datadir/master-bin.000001 + --source include/rpl_end.inc