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
fc9005ad
Commit
fc9005ad
authored
Jun 12, 2024
by
Marko Mäkelä
Browse files
Options
Browse Files
Download
Plain Diff
Merge 10.5 into 10.6
parents
fcd21d3e
f2eda615
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
45 additions
and
16 deletions
+45
-16
client/mysqltest.cc
client/mysqltest.cc
+12
-6
mysql-test/lib/mtr_cases.pm
mysql-test/lib/mtr_cases.pm
+2
-1
mysql-test/main/func_json.test
mysql-test/main/func_json.test
+2
-0
sql/mysqld.cc
sql/mysqld.cc
+11
-4
storage/spider/mysql-test/spider/bugfix/r/mdev_34002.result
storage/spider/mysql-test/spider/bugfix/r/mdev_34002.result
+9
-0
storage/spider/mysql-test/spider/bugfix/t/mdev_34002.test
storage/spider/mysql-test/spider/bugfix/t/mdev_34002.test
+7
-0
storage/spider/spd_db_include.h
storage/spider/spd_db_include.h
+2
-5
No files found.
client/mysqltest.cc
View file @
fc9005ad
...
...
@@ -5922,14 +5922,20 @@ int connect_n_handle_errors(struct st_command *command,
stay clear of trying to work out which exact user-limit was
exceeded.
*/
auto
my_err
=
mysql_errno
(
con
);
if
(
my_err
==
0
)
{
/* Workaround client library bug, not indicating connection error. */
my_err
=
CR_SERVER_LOST
;
}
if
(((
my
sql_errno
(
con
)
==
ER_TOO_MANY_USER_CONNECTIONS
)
||
(
my
sql_errno
(
con
)
==
ER_USER_LIMIT_REACHED
))
&&
if
(((
my
_err
==
ER_TOO_MANY_USER_CONNECTIONS
)
||
(
my
_err
==
ER_USER_LIMIT_REACHED
))
&&
(
failed_attempts
++
<
opt_max_connect_retries
))
{
int
i
;
i
=
match_expected_error
(
command
,
my
sql_errno
(
con
)
,
mysql_sqlstate
(
con
));
i
=
match_expected_error
(
command
,
my
_err
,
mysql_sqlstate
(
con
));
if
(
i
>=
0
)
goto
do_handle_error
;
/* expected error, handle */
...
...
@@ -5939,9 +5945,9 @@ int connect_n_handle_errors(struct st_command *command,
}
do_handle_error:
var_set_errno
(
my
sql_errno
(
con
)
);
handle_error
(
command
,
my
sql_errno
(
con
)
,
mysql_error
(
con
),
mysql_sqlstate
(
con
),
ds
);
var_set_errno
(
my
_err
);
handle_error
(
command
,
my
_err
,
mysql_error
(
con
),
mysql_sqlstate
(
con
),
ds
);
return
0
;
/* Not connected */
}
...
...
mysql-test/lib/mtr_cases.pm
View file @
fc9005ad
...
...
@@ -398,7 +398,8 @@ sub collect_suite_name($$)
{
my
@dirs
=
my_find_dir
(
dirname
(
$::glob_mysql_test_dir
),
["
mysql-test/suite
",
@plugin_suitedirs
],
$suitename
);
$suitename
,
$::opt_skip_not_found
?
NOT_REQUIRED
:
undef
);
#
# if $suitename contained wildcards, we'll have many suites and
# their overlays here. Let's group them appropriately.
...
...
mysql-test/main/func_json.test
View file @
fc9005ad
...
...
@@ -1158,7 +1158,9 @@ SELECT JSON_REMOVE('{"A": { "B": 1 }}', '$.A.B.C.D');
SET
@
save_collation_connection
=
@@
collation_connection
;
SET
collation_connection
=
'utf16_bin'
;
--
disable_service_connection
SELECT
JSON_EXTRACT
(
'{"a": 1,"b": 2}'
,
'$.a'
);
--
enable_service_connection
SET
@@
collation_connection
=
@
save_collation_connection
;
...
...
sql/mysqld.cc
View file @
fc9005ad
...
...
@@ -3108,6 +3108,15 @@ static void start_signal_handler(void)
DBUG_VOID_RETURN
;
}
/** Called only from signal_hand function. */
static
void
*
exit_signal_handler
()
{
my_thread_end
();
signal_thread_in_use
=
0
;
pthread_exit
(
0
);
// Safety
return
nullptr
;
// Avoid compiler warnings
}
/** This threads handles all signals and alarms. */
/* ARGSUSED */
...
...
@@ -3168,10 +3177,7 @@ pthread_handler_t signal_hand(void *arg __attribute__((unused)))
if
(
abort_loop
)
{
DBUG_PRINT
(
"quit"
,(
"signal_handler: calling my_thread_end()"
));
my_thread_end
();
signal_thread_in_use
=
0
;
pthread_exit
(
0
);
// Safety
return
0
;
// Avoid compiler warnings
return
exit_signal_handler
();
}
switch
(
sig
)
{
case
SIGTERM
:
...
...
@@ -3190,6 +3196,7 @@ pthread_handler_t signal_hand(void *arg __attribute__((unused)))
PSI_CALL_delete_current_thread
();
my_sigset
(
sig
,
SIG_IGN
);
break_connect_loop
();
// MIT THREAD has a alarm thread
return
exit_signal_handler
();
}
break
;
case
SIGHUP
:
...
...
storage/spider/mysql-test/spider/bugfix/r/mdev_34002.result
0 → 100644
View file @
fc9005ad
INSTALL PLUGIN Spider SONAME 'ha_spider.so';
CREATE TABLE t (c DATE, c2 VARCHAR(1025) CHARACTER SET utf8mb3, UNIQUE KEY k(c2)) ENGINE=SPIDER;
UPDATE t SET c='2';
ERROR HY000: Unable to connect to foreign data source: localhost
drop table t;
Warnings:
Warning 1620 Plugin is busy and will be uninstalled on shutdown
Note 1305 PLUGIN SPIDER_ALLOC_MEM does not exist
Note 1305 PLUGIN SPIDER_WRAPPER_PROTOCOLS does not exist
storage/spider/mysql-test/spider/bugfix/t/mdev_34002.test
0 → 100644
View file @
fc9005ad
INSTALL
PLUGIN
Spider
SONAME
'ha_spider.so'
;
CREATE
TABLE
t
(
c
DATE
,
c2
VARCHAR
(
1025
)
CHARACTER
SET
utf8mb3
,
UNIQUE
KEY
k
(
c2
))
ENGINE
=
SPIDER
;
--
error
ER_CONNECT_TO_FOREIGN_DATA_SOURCE
UPDATE
t
SET
c
=
'2'
;
drop
table
t
;
--
disable_query_log
--
source
../../
include
/
clean_up_spider
.
inc
storage/spider/spd_db_include.h
View file @
fc9005ad
...
...
@@ -1134,11 +1134,8 @@ class spider_db_handler
ha_spider
*
spider
;
spider_db_share
*
db_share
;
int
first_link_idx
;
#ifdef SPIDER_HAS_GROUP_BY_HANDLER
SPIDER_LINK_IDX_CHAIN
*
link_idx_chain
;
#endif
bool
strict_group_by
;
bool
no_where_cond
;
bool
strict_group_by
=
false
;
bool
no_where_cond
=
false
;
spider_db_handler
(
ha_spider
*
spider
,
spider_db_share
*
db_share
)
:
dbton_id
(
db_share
->
dbton_id
),
spider
(
spider
),
db_share
(
db_share
),
first_link_idx
(
-
1
)
{}
...
...
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