mirror of
https://github.com/MariaDB/server.git
synced 2025-01-20 05:52:27 +01:00
Merged from gca-branch (bug 43110)
This commit is contained in:
commit
780a0aa0ff
1 changed files with 13 additions and 9 deletions
|
@ -946,8 +946,13 @@ set global max_prepared_stmt_count=3;
|
|||
select @@max_prepared_stmt_count;
|
||||
show status like 'prepared_stmt_count';
|
||||
prepare stmt from "select 1";
|
||||
|
||||
connect (con1,localhost,root,,);
|
||||
|
||||
# Switch to connection con1
|
||||
connection con1;
|
||||
let $con1_id=`SELECT CONNECTION_ID()`;
|
||||
|
||||
prepare stmt from "select 2";
|
||||
prepare stmt1 from "select 3";
|
||||
--error ER_MAX_PREPARED_STMT_COUNT_REACHED
|
||||
|
@ -957,18 +962,17 @@ connection default;
|
|||
prepare stmt2 from "select 4";
|
||||
select @@max_prepared_stmt_count;
|
||||
show status like 'prepared_stmt_count';
|
||||
|
||||
# Disconnect connection con1 and switch to default connection
|
||||
disconnect con1;
|
||||
connection default;
|
||||
# Wait for the connection to die: deal with a possible race
|
||||
|
||||
# Wait for the connection con1 to die
|
||||
let $wait_condition=SELECT COUNT(*)=0 FROM information_schema.processlist WHERE id=$con1_id;
|
||||
--source include/wait_condition.inc
|
||||
|
||||
deallocate prepare stmt;
|
||||
let $query= select variable_value from information_schema.global_status
|
||||
where variable_name = 'prepared_stmt_count';
|
||||
let $count= `$query`;
|
||||
if ($count)
|
||||
{
|
||||
--sleep 1
|
||||
let $count= `$query`;
|
||||
}
|
||||
|
||||
select @@max_prepared_stmt_count;
|
||||
show status like 'prepared_stmt_count';
|
||||
#
|
||||
|
|
Loading…
Reference in a new issue