Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
32efbaa1
Commit
32efbaa1
authored
Sep 17, 2019
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-7481 Replace max_long_data_size functionality with max_allowed_packet
parent
12414cd9
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
3 additions
and
116 deletions
+3
-116
mysql-test/main/mysqld--help.result
mysql-test/main/mysqld--help.result
+0
-5
mysql-test/main/variables.result
mysql-test/main/variables.result
+0
-3
mysql-test/main/variables.test
mysql-test/main/variables.test
+0
-5
mysql-test/suite/sys_vars/r/max_long_data_size_basic.result
mysql-test/suite/sys_vars/r/max_long_data_size_basic.result
+0
-14
mysql-test/suite/sys_vars/r/sysvars_server_embedded,32bit.rdiff
...test/suite/sys_vars/r/sysvars_server_embedded,32bit.rdiff
+0
-9
mysql-test/suite/sys_vars/r/sysvars_server_embedded.result
mysql-test/suite/sys_vars/r/sysvars_server_embedded.result
+0
-10
mysql-test/suite/sys_vars/r/sysvars_server_notembedded,32bit.rdiff
...t/suite/sys_vars/r/sysvars_server_notembedded,32bit.rdiff
+0
-9
mysql-test/suite/sys_vars/r/sysvars_server_notembedded.result
...l-test/suite/sys_vars/r/sysvars_server_notembedded.result
+0
-10
mysql-test/suite/sys_vars/t/max_long_data_size_basic.test
mysql-test/suite/sys_vars/t/max_long_data_size_basic.test
+0
-17
sql/item.cc
sql/item.cc
+2
-2
sql/mysqld.cc
sql/mysqld.cc
+0
-18
sql/mysqld.h
sql/mysqld.h
+0
-2
sql/sys_vars.cc
sql/sys_vars.cc
+0
-12
sql/upgrade_conf_file.cc
sql/upgrade_conf_file.cc
+1
-0
No files found.
mysql-test/main/mysqld--help.result
View file @
32efbaa1
...
...
@@ -567,10 +567,6 @@ The following specify which files/extra groups are read (specified before remain
max_join_size records return an error
--max-length-for-sort-data=#
Max number of bytes in sorted records
--max-long-data-size=#
The maximum BLOB length to send to server from
mysql_send_long_data API. Deprecated option; use
max_allowed_packet instead.
--max-password-errors=#
If there is more than this number of failed connect
attempts due to invalid password, user will be blocked
...
...
@@ -1571,7 +1567,6 @@ max-error-count 64
max-heap-table-size 16777216
max-join-size 18446744073709551615
max-length-for-sort-data 1024
max-long-data-size 16777216
max-password-errors 18446744073709551615
max-prepared-stmt-count 16382
max-recursive-iterations 18446744073709551615
...
...
mysql-test/main/variables.result
View file @
32efbaa1
...
...
@@ -1532,9 +1532,6 @@ SET @@global.max_binlog_cache_size=DEFAULT;
SET @@global.max_join_size=DEFAULT;
SET @@global.key_buffer_size=@kbs;
SET @@global.key_cache_block_size=@kcbs;
select @@max_long_data_size > 0;
@@max_long_data_size > 0
1
#
# Bug#11766424 59527:
# Assert in DECIMAL_BIN_SIZE:
...
...
mysql-test/main/variables.test
View file @
32efbaa1
...
...
@@ -1264,11 +1264,6 @@ SET @@global.max_join_size=DEFAULT;
SET
@@
global
.
key_buffer_size
=@
kbs
;
SET
@@
global
.
key_cache_block_size
=@
kcbs
;
#
# Bug#56976: added new start-up parameter
#
select
@@
max_long_data_size
>
0
;
--
echo
#
--
echo
# Bug#11766424 59527:
--
echo
# Assert in DECIMAL_BIN_SIZE:
...
...
mysql-test/suite/sys_vars/r/max_long_data_size_basic.result
deleted
100644 → 0
View file @
12414cd9
select @@global.max_long_data_size=20;
@@global.max_long_data_size=20
0
select @@session.max_long_data_size;
ERROR HY000: Variable 'max_long_data_size' is a GLOBAL variable
SELECT @@global.max_long_data_size = VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
WHERE VARIABLE_NAME='max_long_data_size';
@@global.max_long_data_size = VARIABLE_VALUE
1
set global max_long_data_size=1;
ERROR HY000: Variable 'max_long_data_size' is a read only variable
set session max_long_data_size=1;
ERROR HY000: Variable 'max_long_data_size' is a read only variable
mysql-test/suite/sys_vars/r/sysvars_server_embedded,32bit.rdiff
View file @
32efbaa1
...
...
@@ -521,15 +521,6 @@
VARIABLE_COMMENT Max number of bytes in sorted records
NUMERIC_MIN_VALUE 4
NUMERIC_MAX_VALUE 8388608
@@ -1874,7 +1874,7 @@
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MAX_LONG_DATA_SIZE
VARIABLE_SCOPE GLOBAL
-VARIABLE_TYPE BIGINT UNSIGNED
+VARIABLE_TYPE INT UNSIGNED
VARIABLE_COMMENT The maximum BLOB length to send to server from mysql_send_long_data API. Deprecated option; use max_allowed_packet instead.
NUMERIC_MIN_VALUE 1024
NUMERIC_MAX_VALUE 4294967295
@@ -1904,7 +1904,7 @@
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MAX_RECURSIVE_ITERATIONS
...
...
mysql-test/suite/sys_vars/r/sysvars_server_embedded.result
View file @
32efbaa1
...
...
@@ -1883,16 +1883,6 @@ NUMERIC_BLOCK_SIZE 1
ENUM_VALUE_LIST NULL
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MAX_LONG_DATA_SIZE
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE BIGINT UNSIGNED
VARIABLE_COMMENT The maximum BLOB length to send to server from mysql_send_long_data API. Deprecated option; use max_allowed_packet instead.
NUMERIC_MIN_VALUE 1024
NUMERIC_MAX_VALUE 4294967295
NUMERIC_BLOCK_SIZE 1
ENUM_VALUE_LIST NULL
READ_ONLY YES
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MAX_PASSWORD_ERRORS
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE INT UNSIGNED
...
...
mysql-test/suite/sys_vars/r/sysvars_server_notembedded,32bit.rdiff
View file @
32efbaa1
...
...
@@ -521,15 +521,6 @@
VARIABLE_COMMENT Max number of bytes in sorted records
NUMERIC_MIN_VALUE 4
NUMERIC_MAX_VALUE 8388608
@@ -2024,7 +2024,7 @@
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MAX_LONG_DATA_SIZE
VARIABLE_SCOPE GLOBAL
-VARIABLE_TYPE BIGINT UNSIGNED
+VARIABLE_TYPE INT UNSIGNED
VARIABLE_COMMENT The maximum BLOB length to send to server from mysql_send_long_data API. Deprecated option; use max_allowed_packet instead.
NUMERIC_MIN_VALUE 1024
NUMERIC_MAX_VALUE 4294967295
@@ -2054,7 +2054,7 @@
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MAX_RECURSIVE_ITERATIONS
...
...
mysql-test/suite/sys_vars/r/sysvars_server_notembedded.result
View file @
32efbaa1
...
...
@@ -2033,16 +2033,6 @@ NUMERIC_BLOCK_SIZE 1
ENUM_VALUE_LIST NULL
READ_ONLY NO
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MAX_LONG_DATA_SIZE
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE BIGINT UNSIGNED
VARIABLE_COMMENT The maximum BLOB length to send to server from mysql_send_long_data API. Deprecated option; use max_allowed_packet instead.
NUMERIC_MIN_VALUE 1024
NUMERIC_MAX_VALUE 4294967295
NUMERIC_BLOCK_SIZE 1
ENUM_VALUE_LIST NULL
READ_ONLY YES
COMMAND_LINE_ARGUMENT REQUIRED
VARIABLE_NAME MAX_PASSWORD_ERRORS
VARIABLE_SCOPE GLOBAL
VARIABLE_TYPE INT UNSIGNED
...
...
mysql-test/suite/sys_vars/t/max_long_data_size_basic.test
deleted
100644 → 0
View file @
12414cd9
select
@@
global
.
max_long_data_size
=
20
;
--
error
ER_INCORRECT_GLOBAL_LOCAL_VAR
select
@@
session
.
max_long_data_size
;
# Show that value of the variable matches the value in the GLOBAL I_S table
SELECT
@@
global
.
max_long_data_size
=
VARIABLE_VALUE
FROM
INFORMATION_SCHEMA
.
GLOBAL_VARIABLES
WHERE
VARIABLE_NAME
=
'max_long_data_size'
;
#
# show that it's read-only
#
--
error
ER_INCORRECT_GLOBAL_LOCAL_VAR
set
global
max_long_data_size
=
1
;
--
error
ER_INCORRECT_GLOBAL_LOCAL_VAR
set
session
max_long_data_size
=
1
;
sql/item.cc
View file @
32efbaa1
...
...
@@ -4128,12 +4128,12 @@ bool Item_param::set_longdata(const char *str, ulong length)
(here), and first have to concatenate all pieces together,
write query to the binary log and only then perform conversion.
*/
if
(
value
.
m_string
.
length
()
+
length
>
max_long_data_size
)
if
(
value
.
m_string
.
length
()
+
length
>
current_thd
->
variables
.
max_allowed_packet
)
{
my_message
(
ER_UNKNOWN_ERROR
,
"Parameter of prepared statement which is set through "
"mysql_send_long_data() is longer than "
"'max_
long_data_size
' bytes"
,
"'max_
allowed_packet
' bytes"
,
MYF
(
0
));
DBUG_RETURN
(
true
);
}
...
...
sql/mysqld.cc
View file @
32efbaa1
...
...
@@ -340,7 +340,6 @@ PSI_statement_info stmt_info_rpl;
/* the default log output is log tables */
static
bool
lower_case_table_names_used
=
0
;
static
bool
max_long_data_size_used
=
false
;
static
bool
volatile
select_thread_in_use
,
signal_thread_in_use
;
static
my_bool
opt_debugging
=
0
,
opt_external_locking
=
0
,
opt_console
=
0
;
static
my_bool
opt_short_log_format
=
0
,
opt_silent_startup
=
0
;
...
...
@@ -512,12 +511,6 @@ long opt_secure_timestamp;
uint
default_password_lifetime
;
my_bool
disconnect_on_expired_password
;
/*
Maximum length of parameter value which can be set through
mysql_send_long_data() call.
*/
ulong
max_long_data_size
;
bool
max_user_connections_checking
=
0
;
/**
Limit of the total number of prepared statements in the server.
...
...
@@ -8335,9 +8328,6 @@ mysqld_get_one_option(int optid, const struct my_option *opt, char *argument)
case
OPT_PLUGIN_LOAD_ADD
:
opt_plugin_load_list_ptr
->
push_back
(
new
i_string
(
argument
));
break
;
case
OPT_MAX_LONG_DATA_SIZE
:
max_long_data_size_used
=
true
;
break
;
case
OPT_PFS_INSTRUMENT
:
{
#ifdef WITH_PERFSCHEMA_STORAGE_ENGINE
...
...
@@ -8753,14 +8743,6 @@ static int get_options(int *argc_ptr, char ***argv_ptr)
opt_readonly
=
read_only
;
/*
If max_long_data_size is not specified explicitly use
value of max_allowed_packet.
*/
if
(
!
max_long_data_size_used
)
SYSVAR_AUTOSIZE
(
max_long_data_size
,
global_system_variables
.
max_allowed_packet
);
/* Remember if max_user_connections was 0 at startup */
max_user_connections_checking
=
global_system_variables
.
max_user_connections
!=
0
;
...
...
sql/mysqld.h
View file @
32efbaa1
...
...
@@ -157,7 +157,6 @@ extern plugin_ref *opt_gtid_pos_auto_plugins;
extern
bool
opt_endinfo
,
using_udf_functions
;
extern
my_bool
locked_in_memory
;
extern
bool
opt_using_transactions
;
extern
ulong
max_long_data_size
;
extern
ulong
current_pid
;
extern
ulong
expire_logs_days
;
extern
my_bool
relay_log_recovery
;
...
...
@@ -668,7 +667,6 @@ enum options_mysqld
OPT_LOG_BASENAME
,
OPT_LOG_ERROR
,
OPT_LOWER_CASE_TABLE_NAMES
,
OPT_MAX_LONG_DATA_SIZE
,
OPT_PLUGIN_LOAD
,
OPT_PLUGIN_LOAD_ADD
,
OPT_PFS_INSTRUMENT
,
...
...
sql/sys_vars.cc
View file @
32efbaa1
...
...
@@ -2320,18 +2320,6 @@ static Sys_var_ulong Sys_max_length_for_sort_data(
SESSION_VAR
(
max_length_for_sort_data
),
CMD_LINE
(
REQUIRED_ARG
),
VALID_RANGE
(
4
,
8192
*
1024L
),
DEFAULT
(
1024
),
BLOCK_SIZE
(
1
));
static
Sys_var_ulong
Sys_max_long_data_size
(
"max_long_data_size"
,
"The maximum BLOB length to send to server from "
"mysql_send_long_data API. Deprecated option; "
"use max_allowed_packet instead."
,
READ_ONLY
GLOBAL_VAR
(
max_long_data_size
),
CMD_LINE
(
REQUIRED_ARG
,
OPT_MAX_LONG_DATA_SIZE
),
VALID_RANGE
(
1024
,
UINT_MAX32
),
DEFAULT
(
1024
*
1024
),
BLOCK_SIZE
(
1
),
NO_MUTEX_GUARD
,
NOT_IN_BINLOG
,
ON_CHECK
(
0
),
ON_UPDATE
(
0
),
DEPRECATED
(
"'@@max_allowed_packet'"
));
static
PolyLock_mutex
PLock_prepared_stmt_count
(
&
LOCK_prepared_stmt_count
);
static
Sys_var_uint
Sys_max_prepared_stmt_count
(
"max_prepared_stmt_count"
,
...
...
sql/upgrade_conf_file.cc
View file @
32efbaa1
...
...
@@ -115,6 +115,7 @@ static const char *removed_variables[] =
"innodb_use_trim"
,
"log"
,
"log_slow_queries"
,
"max_long_data_size"
,
"rpl_recovery_rank"
,
"sql_big_tables"
,
"sql_low_priority_updates"
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment