Commit cafba876 authored by Oleksandr Byelkin's avatar Oleksandr Byelkin

Merge branch '10.10' into 10.11

parents c7c41573 cc8b9bce
--- mysql-test/main/select.result 2023-01-31 09:30:58.151377805 +0100
+++ mysql-test/main/select.reject 2023-02-01 13:44:11.026958614 +0100
@@ -5661,6 +5661,8 @@
Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
Note 1249 Select 2 was reduced during optimization
+Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
+Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
Note 1003 /* select#1 */ select `test`.`t1`.`a` AS `a` from `test`.`t1` where `test`.`t1`.`a` = 1 and (1 or <expr_cache><`test`.`t1`.`a`>((/* select#3 */ select 3 from DUAL where `test`.`t1`.`a` = `test`.`t1`.`a`)) = 3)
PREPARE stmt FROM 'SELECT * FROM t1 WHERE a = 1 AND
(3 = 0 OR (SELECT a = 1 OR (SELECT 3 WHERE a = a) = 3))';
......@@ -3,6 +3,7 @@
#
--source include/no_valgrind_without_big.inc
--source include/protocol.inc
#
# Simple select test
......@@ -4758,9 +4759,11 @@ INSERT INTO t1 VALUES (1),(2),(3);
SELECT * FROM t1 WHERE a = 1 AND
(3 = 0 OR (SELECT a = 1 OR (SELECT 3 WHERE a = a) = 3));
--enable_prepare_warnings
EXPLAIN EXTENDED
SELECT * FROM t1 WHERE a = 1 AND
(3 = 0 OR (SELECT a = 1 OR (SELECT 3 WHERE a = a) = 3));
--disable_prepare_warnings
PREPARE stmt FROM 'SELECT * FROM t1 WHERE a = 1 AND
(3 = 0 OR (SELECT a = 1 OR (SELECT 3 WHERE a = a) = 3))';
......
--- mysql-test/main/select_jcl6.result 2023-01-31 09:30:58.151377805 +0100
+++ mysql-test/main/select_jcl6.reject 2023-02-01 13:44:10.722958771 +0100
@@ -5672,6 +5672,8 @@
Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
Note 1249 Select 2 was reduced during optimization
+Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
+Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
Note 1003 /* select#1 */ select `test`.`t1`.`a` AS `a` from `test`.`t1` where `test`.`t1`.`a` = 1 and (1 or <expr_cache><`test`.`t1`.`a`>((/* select#3 */ select 3 from DUAL where `test`.`t1`.`a` = `test`.`t1`.`a`)) = 3)
PREPARE stmt FROM 'SELECT * FROM t1 WHERE a = 1 AND
(3 = 0 OR (SELECT a = 1 OR (SELECT 3 WHERE a = a) = 3))';
--- mysql-test/main/select_pkeycache.result 2023-01-31 09:30:58.151377805 +0100
+++ mysql-test/main/select_pkeycache.reject 2023-02-01 13:43:21.742985365 +0100
@@ -5661,6 +5661,8 @@
Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
Note 1249 Select 2 was reduced during optimization
+Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
+Note 1276 Field or reference 'test.t1.a' of SELECT #3 was resolved in SELECT #1
Note 1003 /* select#1 */ select `test`.`t1`.`a` AS `a` from `test`.`t1` where `test`.`t1`.`a` = 1 and (1 or <expr_cache><`test`.`t1`.`a`>((/* select#3 */ select 3 from DUAL where `test`.`t1`.`a` = `test`.`t1`.`a`)) = 3)
PREPARE stmt FROM 'SELECT * FROM t1 WHERE a = 1 AND
(3 = 0 OR (SELECT a = 1 OR (SELECT 3 WHERE a = a) = 3))';
......@@ -26,3 +26,4 @@ galera_var_ignore_apply_errors : 28: "Server did not transition to READY state"
galera_bf_kill_debug : timeout after 900 seconds
galera_ssl_upgrade : [Warning] Failed to load slave replication state from table mysql.gtid_slave_pos: 130: Incorrect file format 'gtid_slave_pos'
galera_parallel_simple : timeout related to wsrep_sync_wait
galera_insert_bulk : MDEV-30536 no expected deadlock in galera_insert_bulk test
......@@ -84,7 +84,7 @@ SET DEBUG_SYNC = "now SIGNAL continue_kill";
--reap
--connection node_2a
--error 0,1213,2013
--error 0,1213,2013,2026
select * from t1;
--connection node_2
......
......@@ -30,7 +30,7 @@ SELECT * FROM t1;
SET GLOBAL wsrep_reject_queries = ALL_KILL;
--connection node_1a
--error ER_CONNECTION_KILLED,2013,2006
--error ER_CONNECTION_KILLED,2013,2006,2026
SELECT * FROM t1;
--connect node_1b, 127.0.0.1, root, , test, $NODE_MYPORT_1
......
......@@ -10,3 +10,18 @@ FLUSH TABLE t1 FOR EXPORT;
UNLOCK TABLES;
NOT FOUND /unicycle|repairman/ in t1.ibd
DROP TABLE t1;
#
# MDEV-30527 Assertion !m_freed_pages in mtr_t::start()
# on DROP TEMPORARY TABLE
#
SET @scrub= @@GLOBAL.innodb_immediate_scrub_data_uncompressed;
SET GLOBAL innodb_immediate_scrub_data_uncompressed= 1;
SET @fpt=@@GLOBAL.innodb_file_per_table;
SET GLOBAL innodb_file_per_table=0;
CREATE TABLE t ENGINE=InnoDB AS SELECT 1;
DROP TABLE t;
SET GLOBAL innodb_file_per_table=@fpt;
CREATE TEMPORARY TABLE tmp ENGINE=InnoDB AS SELECT 1;
DROP TABLE tmp;
SET GLOBAL INNODB_IMMEDIATE_SCRUB_DATA_UNCOMPRESSED= @scrub;
# End of 10.6 tests
......@@ -22,6 +22,6 @@ delete from t1 where a=3;
set global innodb_fast_shutdown=0;
ERROR 42000: Variable 'innodb_fast_shutdown' can't be set to the value of '0'
kill ID;
ERROR 70100: Connection was killed
Got one of the listed errors
# restart
drop table t1;
......@@ -38,7 +38,7 @@ let $wait_condition =
# depending on platform.
#
connection con1;
-- error 1317, 2006, 2013, ER_CONNECTION_KILLED
-- error 1317, 2006, 2013, ER_CONNECTION_KILLED, 2026
reap;
connection default;
DROP TABLE bug51920;
......
......@@ -27,3 +27,19 @@ FLUSH TABLE t1 FOR EXPORT;
UNLOCK TABLES;
-- source include/search_pattern_in_file.inc
DROP TABLE t1;
--echo #
--echo # MDEV-30527 Assertion !m_freed_pages in mtr_t::start()
--echo # on DROP TEMPORARY TABLE
--echo #
SET @scrub= @@GLOBAL.innodb_immediate_scrub_data_uncompressed;
SET GLOBAL innodb_immediate_scrub_data_uncompressed= 1;
SET @fpt=@@GLOBAL.innodb_file_per_table;
SET GLOBAL innodb_file_per_table=0;
CREATE TABLE t ENGINE=InnoDB AS SELECT 1;
DROP TABLE t;
SET GLOBAL innodb_file_per_table=@fpt;
CREATE TEMPORARY TABLE tmp ENGINE=InnoDB AS SELECT 1;
DROP TABLE tmp;
SET GLOBAL INNODB_IMMEDIATE_SCRUB_DATA_UNCOMPRESSED= @scrub;
--echo # End of 10.6 tests
......@@ -36,7 +36,7 @@ set global innodb_fast_shutdown=0;
# the error code
let $me=`select concat(' ', connection_id())`;
replace_result $me ID;
error ER_CONNECTION_KILLED;
error ER_CONNECTION_KILLED, 2026;
eval kill $me;
source include/start_mysqld.inc;
......
......@@ -143,7 +143,7 @@ let $counter= 5000;
let $mysql_errno= 9999;
while ($mysql_errno)
{
--error 0,ER_SERVER_SHUTDOWN,ER_CONNECTION_KILLED,2002,2006,2013
--error 0,ER_SERVER_SHUTDOWN,ER_CONNECTION_KILLED,2002,2006,2013,2026
select 1;
dec $counter;
......
......@@ -146,7 +146,7 @@ COMMIT;
--echo ## Inserting rows should give error here because connection should ##
--echo ## disconnect after using COMMIT ##
--Error 2006,2013,ER_QUERY_INTERRUPTED,ER_CONNECTION_KILLED,5014
--Error 2006,2013,ER_QUERY_INTERRUPTED,ER_CONNECTION_KILLED,5014,2026
INSERT INTO t1 VALUES(4,'Record_4');
connection test_con2;
......@@ -160,7 +160,7 @@ INSERT INTO t1 VALUES(12,'Record_12');
ROLLBACK;
--echo ## Expect a failure due to COMMIT/ROLLBACK AND RELEASE behavior ##
--Error 2006,2013,ER_QUERY_INTERRUPTED,ER_CONNECTION_KILLED,5014
--Error 2006,2013,ER_QUERY_INTERRUPTED,ER_CONNECTION_KILLED,5014,2026
INSERT INTO t1 VALUES(4,'Record_4');
connection default;
......
......@@ -43,7 +43,7 @@ let $counter= 80;
let $mysql_errno= 0;
while (!$mysql_errno)
{
--error 0,ER_SERVER_SHUTDOWN,ER_CONNECTION_KILLED,2002,2006,2013,5014
--error 0,ER_SERVER_SHUTDOWN,ER_CONNECTION_KILLED,2002,2006,2013,5014,2026
show status;
dec $counter;
......
......@@ -1890,6 +1890,7 @@ dberr_t btr_cur_t::open_leaf(bool first, dict_index_t *index,
ut_ad(root_leaf_rw_latch != RW_NO_LATCH);
upper_rw_latch= root_leaf_rw_latch;
mtr->rollback_to_savepoint(savepoint);
height= ULINT_UNDEFINED;
continue;
}
else
......
......@@ -459,7 +459,20 @@ void mtr_t::commit()
buf_flush_ahead(m_commit_lsn, lsns.second == PAGE_FLUSH_SYNC);
}
else
{
if (m_freed_pages)
{
ut_ad(!m_freed_pages->empty());
ut_ad(m_freed_space == fil_system.temp_space);
ut_ad(!m_trim_pages);
for (const auto &range : *m_freed_pages)
m_freed_space->add_free_range(range);
delete m_freed_pages;
m_freed_pages= nullptr;
m_freed_space= nullptr;
}
release();
}
func_exit:
release_resources();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment