Commit ad17aa11 authored by Vicențiu Ciorbaru's avatar Vicențiu Ciorbaru

MDEV-18650: Options deprecated in previous versions - multi_range_count

Remove deprecated system variable multi_range_count. It was ignored from 5.3.
parent 5aebd78e
......@@ -616,8 +616,6 @@ The following specify which files/extra groups are read (specified before remain
Don't write queries to slow log that examine fewer rows
than that
--mrr-buffer-size=# Size of buffer to use when using MRR with range access
--multi-range-count=#
Ignored. Use mrr_buffer_size instead
--myisam-block-size=#
Block size to be used for MyISAM index pages
--myisam-data-pointer-size=#
......@@ -1582,7 +1580,6 @@ metadata-locks-cache-size 1024
metadata-locks-hash-instances 8
min-examined-row-limit 0
mrr-buffer-size 262144
multi-range-count 256
myisam-block-size 1024
myisam-data-pointer-size 6
myisam-max-sort-file-size 9223372036853727232
......
SET @start_global_value = @@global.multi_range_count;
SELECT @start_global_value;
@start_global_value
256
SET @start_session_value = @@session.multi_range_count;
SELECT @start_session_value;
@start_session_value
256
'#--------------------FN_DYNVARS_090_01-------------------------#'
SET @@global.multi_range_count = 100;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SET @@global.multi_range_count = DEFAULT;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@global.multi_range_count;
@@global.multi_range_count
256
SET @@session.multi_range_count = 200;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SET @@session.multi_range_count = DEFAULT;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@session.multi_range_count;
@@session.multi_range_count
256
'#--------------------FN_DYNVARS_090_02-------------------------#'
SET @@global.multi_range_count = DEFAULT;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@global.multi_range_count = 256;
@@global.multi_range_count = 256
1
SET @@session.multi_range_count = DEFAULT;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@session.multi_range_count = 256;
@@session.multi_range_count = 256
1
'#--------------------FN_DYNVARS_090_03-------------------------#'
SET @@global.multi_range_count = 1;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@global.multi_range_count;
@@global.multi_range_count
1
SET @@global.multi_range_count = 60020;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@global.multi_range_count;
@@global.multi_range_count
60020
SET @@global.multi_range_count = 65535;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@global.multi_range_count;
@@global.multi_range_count
65535
SET @@global.multi_range_count = 4294967295;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@global.multi_range_count;
@@global.multi_range_count
4294967295
SET @@global.multi_range_count = 4294967294;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@global.multi_range_count;
@@global.multi_range_count
4294967294
'#--------------------FN_DYNVARS_090_04-------------------------#'
SET @@session.multi_range_count = 1;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@session.multi_range_count;
@@session.multi_range_count
1
SET @@session.multi_range_count = 50050;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@session.multi_range_count;
@@session.multi_range_count
50050
SET @@session.multi_range_count = 65535;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@session.multi_range_count;
@@session.multi_range_count
65535
SET @@session.multi_range_count = 4294967295;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@session.multi_range_count;
@@session.multi_range_count
4294967295
SET @@session.multi_range_count = 4294967294;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@session.multi_range_count;
@@session.multi_range_count
4294967294
'#------------------FN_DYNVARS_090_05-----------------------#'
SET @@global.multi_range_count = 0;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
Warning 1292 Truncated incorrect multi_range_count value: '0'
SELECT @@global.multi_range_count;
@@global.multi_range_count
1
SET @@global.multi_range_count = 4294967296;
SELECT @@global.multi_range_count;
@@global.multi_range_count
4294967295
SET @@global.multi_range_count = -1024;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
Warning 1292 Truncated incorrect multi_range_count value: '-1024'
SELECT @@global.multi_range_count;
@@global.multi_range_count
1
SET @@global.multi_range_count = 429496729500;
SELECT @@global.multi_range_count;
@@global.multi_range_count
4294967295
SET @@global.multi_range_count = 65530.34;
ERROR 42000: Incorrect argument type to variable 'multi_range_count'
SELECT @@global.multi_range_count;
@@global.multi_range_count
4294967295
SET @@global.multi_range_count = test;
ERROR 42000: Incorrect argument type to variable 'multi_range_count'
SELECT @@global.multi_range_count;
@@global.multi_range_count
4294967295
SET @@session.multi_range_count = 0;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
Warning 1292 Truncated incorrect multi_range_count value: '0'
SELECT @@session.multi_range_count;
@@session.multi_range_count
1
SET @@session.multi_range_count = 4294967296;
SELECT @@session.multi_range_count;
@@session.multi_range_count
4294967295
SET @@session.multi_range_count = -1;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
Warning 1292 Truncated incorrect multi_range_count value: '-1'
SELECT @@session.multi_range_count;
@@session.multi_range_count
1
SET @@session.multi_range_count = 65530.34.;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '.' at line 1
SET @@session.multi_range_count = 4294967295021;
SELECT @@session.multi_range_count;
@@session.multi_range_count
4294967295
'Bug # 34837: Errors are not coming on assigning invalid values to variable';
SET @@session.multi_range_count = test;
ERROR 42000: Incorrect argument type to variable 'multi_range_count'
SELECT @@session.multi_range_count;
@@session.multi_range_count
4294967295
'#------------------FN_DYNVARS_090_06-----------------------#'
SELECT @@global.multi_range_count = VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='multi_range_count';
@@global.multi_range_count = VARIABLE_VALUE
1
'#------------------FN_DYNVARS_090_07-----------------------#'
SELECT @@session.multi_range_count = VARIABLE_VALUE
FROM INFORMATION_SCHEMA.SESSION_VARIABLES
WHERE VARIABLE_NAME='multi_range_count';
@@session.multi_range_count = VARIABLE_VALUE
1
'#------------------FN_DYNVARS_090_08-----------------------#'
SET @@global.multi_range_count = TRUE;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@global.multi_range_count;
@@global.multi_range_count
1
SET @@global.multi_range_count = FALSE;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
Warning 1292 Truncated incorrect multi_range_count value: '0'
SELECT @@global.multi_range_count;
@@global.multi_range_count
1
'#---------------------FN_DYNVARS_090_09----------------------#'
SET @@global.multi_range_count = 10;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@multi_range_count = @@global.multi_range_count;
@@multi_range_count = @@global.multi_range_count
0
'#---------------------FN_DYNVARS_090_10----------------------#'
SET @@multi_range_count = 100;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@multi_range_count = @@local.multi_range_count;
@@multi_range_count = @@local.multi_range_count
1
SELECT @@local.multi_range_count = @@session.multi_range_count;
@@local.multi_range_count = @@session.multi_range_count
1
'#---------------------FN_DYNVARS_090_11----------------------#'
SET multi_range_count = 1;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@multi_range_count;
@@multi_range_count
1
SELECT local.multi_range_count;
ERROR 42S02: Unknown table 'local' in field list
SELECT session.multi_range_count;
ERROR 42S02: Unknown table 'session' in field list
SELECT multi_range_count = @@session.multi_range_count;
ERROR 42S22: Unknown column 'multi_range_count' in 'field list'
SET @@global.multi_range_count = @start_global_value;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@global.multi_range_count;
@@global.multi_range_count
256
SET @@session.multi_range_count = @start_session_value;
Warnings:
Warning 1287 '@@multi_range_count' is deprecated and will be removed in a future release. Please use '@@mrr_buffer_size' instead
SELECT @@session.multi_range_count;
@@session.multi_range_count
256
......@@ -2043,16 +2043,6 @@ NUMERIC_BLOCK_SIZE 1
ENUM_VALUE_LIST NULL
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MULTI_RANGE_COUNT
VARIABLE_SCOPE SESSION
VARIABLE_TYPE BIGINT UNSIGNED
VARIABLE_COMMENT Ignored. Use mrr_buffer_size instead
NUMERIC_MIN_VALUE 1
NUMERIC_MAX_VALUE 18446744073709551615
NUMERIC_BLOCK_SIZE 1
ENUM_VALUE_LIST NULL
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MYISAM_BLOCK_SIZE
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE BIGINT UNSIGNED
......
......@@ -2203,16 +2203,6 @@ NUMERIC_BLOCK_SIZE 1
ENUM_VALUE_LIST NULL
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MULTI_RANGE_COUNT
VARIABLE_SCOPE SESSION
VARIABLE_TYPE BIGINT UNSIGNED
VARIABLE_COMMENT Ignored. Use mrr_buffer_size instead
NUMERIC_MIN_VALUE 1
NUMERIC_MAX_VALUE 18446744073709551615
NUMERIC_BLOCK_SIZE 1
ENUM_VALUE_LIST NULL
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MYISAM_BLOCK_SIZE
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE BIGINT UNSIGNED
......
############## mysql-test\t\multi_range_count_basic.test ###############
# #
# Variable Name: multi_range_count #
# Scope: GLOBAL | SESSION #
# Access Type: Dynamic #
# Data Type: numeric #
# Default Value: 256 #
# Range:1-4294967295 #
# #
# #
# Creation Date: 2008-02-07 #
# Author: Salman #
# #
# Description: Test Cases of Dynamic System Variable multi_range_count #
# that checks the behavior of this variable in the following ways#
# * Default Value #
# * Valid & Invalid values #
# * Scope & Access method #
# * Data Integrity #
# #
# Reference: http://dev.mysql.com/doc/refman/5.1/en/ #
# server-system-variables.html #
# #
###############################################################################
--source include/load_sysvars.inc
#################################################################
# START OF multi_range_count TESTS #
#################################################################
#############################################################
# Save initial value #
#############################################################
SET @start_global_value = @@global.multi_range_count;
SELECT @start_global_value;
SET @start_session_value = @@session.multi_range_count;
SELECT @start_session_value;
--echo '#--------------------FN_DYNVARS_090_01-------------------------#'
#################################################################
# Display the DEFAULT value of multi_range_count #
#################################################################
SET @@global.multi_range_count = 100;
SET @@global.multi_range_count = DEFAULT;
SELECT @@global.multi_range_count;
SET @@session.multi_range_count = 200;
SET @@session.multi_range_count = DEFAULT;
SELECT @@session.multi_range_count;
--echo '#--------------------FN_DYNVARS_090_02-------------------------#'
#################################################################
# Check the DEFAULT value of multi_range_count #
#################################################################
SET @@global.multi_range_count = DEFAULT;
SELECT @@global.multi_range_count = 256;
SET @@session.multi_range_count = DEFAULT;
SELECT @@session.multi_range_count = 256;
--echo '#--------------------FN_DYNVARS_090_03-------------------------#'
###########################################################################
# Change the value of multi_range_count to a valid value for GLOBAL Scope #
###########################################################################
SET @@global.multi_range_count = 1;
SELECT @@global.multi_range_count;
SET @@global.multi_range_count = 60020;
SELECT @@global.multi_range_count;
SET @@global.multi_range_count = 65535;
SELECT @@global.multi_range_count;
SET @@global.multi_range_count = 4294967295;
SELECT @@global.multi_range_count;
SET @@global.multi_range_count = 4294967294;
SELECT @@global.multi_range_count;
--echo '#--------------------FN_DYNVARS_090_04-------------------------#'
############################################################################
# Change the value of multi_range_count to a valid value for SESSION Scope #
############################################################################
SET @@session.multi_range_count = 1;
SELECT @@session.multi_range_count;
SET @@session.multi_range_count = 50050;
SELECT @@session.multi_range_count;
SET @@session.multi_range_count = 65535;
SELECT @@session.multi_range_count;
SET @@session.multi_range_count = 4294967295;
SELECT @@session.multi_range_count;
SET @@session.multi_range_count = 4294967294;
SELECT @@session.multi_range_count;
--echo '#------------------FN_DYNVARS_090_05-----------------------#'
#############################################################
# Change the value of multi_range_count to an invalid value #
#############################################################
SET @@global.multi_range_count = 0;
SELECT @@global.multi_range_count;
--disable_warnings
SET @@global.multi_range_count = 4294967296;
--enable_warnings
--replace_result 4294967296 4294967295
SELECT @@global.multi_range_count;
SET @@global.multi_range_count = -1024;
SELECT @@global.multi_range_count;
--disable_warnings
SET @@global.multi_range_count = 429496729500;
--enable_warnings
--replace_result 429496729500 4294967295
SELECT @@global.multi_range_count;
--Error ER_WRONG_TYPE_FOR_VAR
SET @@global.multi_range_count = 65530.34;
--replace_result 429496729500 4294967295
SELECT @@global.multi_range_count;
--Error ER_WRONG_TYPE_FOR_VAR
SET @@global.multi_range_count = test;
--replace_result 429496729500 4294967295
SELECT @@global.multi_range_count;
SET @@session.multi_range_count = 0;
SELECT @@session.multi_range_count;
--disable_warnings
SET @@session.multi_range_count = 4294967296;
--enable_warnings
--replace_result 4294967296 4294967295
SELECT @@session.multi_range_count;
SET @@session.multi_range_count = -1;
SELECT @@session.multi_range_count;
--Error ER_PARSE_ERROR
SET @@session.multi_range_count = 65530.34.;
--disable_warnings
SET @@session.multi_range_count = 4294967295021;
--enable_warnings
--replace_result 4294967295021 4294967295
SELECT @@session.multi_range_count;
--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable';
--Error ER_WRONG_TYPE_FOR_VAR
SET @@session.multi_range_count = test;
--replace_result 4294967295021 4294967295
SELECT @@session.multi_range_count;
--echo '#------------------FN_DYNVARS_090_06-----------------------#'
####################################################################
# Check if the value in GLOBAL Table matches value in variable #
####################################################################
SELECT @@global.multi_range_count = VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='multi_range_count';
--echo '#------------------FN_DYNVARS_090_07-----------------------#'
####################################################################
# Check if the value in SESSION Table matches value in variable #
####################################################################
SELECT @@session.multi_range_count = VARIABLE_VALUE
FROM INFORMATION_SCHEMA.SESSION_VARIABLES
WHERE VARIABLE_NAME='multi_range_count';
--echo '#------------------FN_DYNVARS_090_08-----------------------#'
####################################################################
# Check if TRUE and FALSE values can be used on variable #
####################################################################
SET @@global.multi_range_count = TRUE;
SELECT @@global.multi_range_count;
SET @@global.multi_range_count = FALSE;
SELECT @@global.multi_range_count;
--echo '#---------------------FN_DYNVARS_090_09----------------------#'
#################################################################################
# Check if accessing variable with and without GLOBAL point to same variable #
#################################################################################
SET @@global.multi_range_count = 10;
SELECT @@multi_range_count = @@global.multi_range_count;
--echo '#---------------------FN_DYNVARS_090_10----------------------#'
########################################################################################################
# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable #
########################################################################################################
SET @@multi_range_count = 100;
SELECT @@multi_range_count = @@local.multi_range_count;
SELECT @@local.multi_range_count = @@session.multi_range_count;
--echo '#---------------------FN_DYNVARS_090_11----------------------#'
############################################################################
# Check if multi_range_count can be accessed with and without @@ sign #
############################################################################
SET multi_range_count = 1;
SELECT @@multi_range_count;
--Error ER_UNKNOWN_TABLE
SELECT local.multi_range_count;
--Error ER_UNKNOWN_TABLE
SELECT session.multi_range_count;
--Error ER_BAD_FIELD_ERROR
SELECT multi_range_count = @@session.multi_range_count;
####################################
# Restore initial value #
####################################
SET @@global.multi_range_count = @start_global_value;
SELECT @@global.multi_range_count;
SET @@session.multi_range_count = @start_session_value;
SELECT @@session.multi_range_count;
######################################################
# END OF multi_range_count TESTS #
######################################################
......@@ -2334,7 +2334,6 @@ typedef struct loc_system_variables
ulong max_tmp_tables;
ulong max_insert_delayed_threads;
ulong min_examined_row_limit;
ulong multi_range_count;
ulong net_buffer_length;
ulong net_interactive_timeout;
ulong net_read_timeout;
......
......@@ -5050,6 +5050,8 @@ static int init_server_components()
compatibility, but do not have any effect otherwise, they behave
as if supplied with --loose. Whenever a deprecated option is removed
it should be appended here. */
{"multi-range-count", OPT_DEPRECATED_OPTION, "",
0, 0, 0, GET_NO_ARG, OPT_ARG, 0, 0, 0, 0, 0, 0},
{"skip-bdb", OPT_DEPRECATED_OPTION, "",
0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{"thread-concurrency", OPT_DEPRECATED_OPTION, "",
......
......@@ -643,7 +643,6 @@ typedef struct system_variables
ulong max_tmp_tables;
ulong max_insert_delayed_threads;
ulong min_examined_row_limit;
ulong multi_range_count;
ulong net_buffer_length;
ulong net_interactive_timeout;
ulong net_read_timeout;
......
......@@ -2803,13 +2803,6 @@ static Sys_var_ulong Sys_range_alloc_block_size(
VALID_RANGE(RANGE_ALLOC_BLOCK_SIZE, UINT_MAX),
DEFAULT(RANGE_ALLOC_BLOCK_SIZE), BLOCK_SIZE(1024));
static Sys_var_ulong Sys_multi_range_count(
"multi_range_count", "Ignored. Use mrr_buffer_size instead",
SESSION_VAR(multi_range_count), CMD_LINE(REQUIRED_ARG),
VALID_RANGE(1, ULONG_MAX), DEFAULT(256), BLOCK_SIZE(1),
NO_MUTEX_GUARD, NOT_IN_BINLOG, ON_CHECK(0), ON_UPDATE(0),
DEPRECATED("'@@mrr_buffer_size'"));
static bool fix_thd_mem_root(sys_var *self, THD *thd, enum_var_type type)
{
if (type != OPT_GLOBAL)
......
......@@ -116,6 +116,7 @@ static const char *removed_variables[] =
"log",
"log_slow_queries",
"max_long_data_size",
"multi_range_count",
"rpl_recovery_rank",
"skip_bdb",
"sql_big_tables",
......
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