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
58c293f2
Commit
58c293f2
authored
Jul 18, 2024
by
Yuchen Pei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[demo][debug] spider: debugging MDEV-27438
parent
70e3c144
Changes
9
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
204 additions
and
172 deletions
+204
-172
mysql-test/include/wait_show_condition.inc
mysql-test/include/wait_show_condition.inc
+2
-1
mysql-test/suite/binlog/t/binlog_checkpoint_flush_logs.test
mysql-test/suite/binlog/t/binlog_checkpoint_flush_logs.test
+1
-1
mysql-test/suite/binlog/t/binlog_mdev342.test
mysql-test/suite/binlog/t/binlog_mdev342.test
+6
-2
mysql-test/suite/binlog/t/binlog_truncate_multi_log.test
mysql-test/suite/binlog/t/binlog_truncate_multi_log.test
+1
-0
mysql-test/suite/binlog/t/binlog_truncate_multi_log_unsafe.test
...test/suite/binlog/t/binlog_truncate_multi_log_unsafe.test
+1
-0
mysql-test/suite/binlog/t/binlog_xa_recover.test
mysql-test/suite/binlog/t/binlog_xa_recover.test
+179
-163
sql/handler.cc
sql/handler.cc
+1
-0
sql/log.cc
sql/log.cc
+7
-5
storage/spider/spd_trx.cc
storage/spider/spd_trx.cc
+6
-0
No files found.
mysql-test/include/wait_show_condition.inc
View file @
58c293f2
...
@@ -77,7 +77,8 @@ if ($wait_for_all != 1)
...
@@ -77,7 +77,8 @@ if ($wait_for_all != 1)
while
(
$do_loop
)
while
(
$do_loop
)
{
{
let
$field_value
=
query_get_value
(
$show_statement
,
$field
,
$rowno
);
let
$field_value
=
query_get_value
(
$show_statement
,
$field
,
$rowno
);
if
(
`SELECT '$field_value' $condition`
)
# let $field_value= `select quote($field_value)`;
if
(
`SELECT "$field_value" $condition`
)
{
{
let
$found
=
1
;
let
$found
=
1
;
let
$do_loop
=
0
;
let
$do_loop
=
0
;
...
...
mysql-test/suite/binlog/t/binlog_checkpoint_flush_logs.test
View file @
58c293f2
...
@@ -54,7 +54,7 @@ SET DEBUG_SYNC= "now SIGNAL default_go";
...
@@ -54,7 +54,7 @@ SET DEBUG_SYNC= "now SIGNAL default_go";
connection
default
;
connection
default
;
--
enable_reconnect
--
enable_reconnect
--
error
0
,
2013
--
error
0
,
2013
--
reap
--
reap
# sigabrt
--
echo
Must
be
tree
logs
in
the
list
:
--
echo
Must
be
tree
logs
in
the
list
:
--
source
include
/
show_binary_logs
.
inc
--
source
include
/
show_binary_logs
.
inc
...
...
mysql-test/suite/binlog/t/binlog_mdev342.test
View file @
58c293f2
...
@@ -10,7 +10,11 @@ SET GLOBAL max_binlog_size= 4096;
...
@@ -10,7 +10,11 @@ SET GLOBAL max_binlog_size= 4096;
SET
GLOBAL
innodb_flush_log_at_trx_commit
=
1
;
SET
GLOBAL
innodb_flush_log_at_trx_commit
=
1
;
RESET
MASTER
;
RESET
MASTER
;
CREATE
TABLE
t1
(
a
INT
PRIMARY
KEY
,
b
MEDIUMTEXT
)
ENGINE
=
Innodb
;
install
soname
'ha_spider'
;
set
spider_same_server_link
=
1
;
evalp
CREATE
SERVER
srv
FOREIGN
DATA
WRAPPER
MYSQL
OPTIONS
(
SOCKET
"
$MASTER_MYSOCK
"
,
DATABASE
'test'
,
user
'root'
);
create
table
t2
(
a
INT
PRIMARY
KEY
,
b
MEDIUMTEXT
);
CREATE
TABLE
t1
(
a
INT
PRIMARY
KEY
,
b
MEDIUMTEXT
)
ENGINE
=
Spider
COMMENT
=
"srv 'srv', table 't2'"
;
# MDEV-515 takes X-lock on the table for the first insert
# MDEV-515 takes X-lock on the table for the first insert
# In that case, Concurrent DML will get blocked
# In that case, Concurrent DML will get blocked
INSERT
INTO
t1
VALUES
(
100
,
"MDEV-515"
);
INSERT
INTO
t1
VALUES
(
100
,
"MDEV-515"
);
...
@@ -44,7 +48,7 @@ EOF
...
@@ -44,7 +48,7 @@ EOF
SET
DEBUG_SYNC
=
"now SIGNAL con1_cont"
;
SET
DEBUG_SYNC
=
"now SIGNAL con1_cont"
;
connection
con1
;
connection
con1
;
--
error
2006
,
2013
--
error
2006
,
2013
reap
;
reap
;
# sigabrt
--
append_file
$MYSQLTEST_VARDIR
/
tmp
/
mysqld
.
1.
expect
--
append_file
$MYSQLTEST_VARDIR
/
tmp
/
mysqld
.
1.
expect
restart
-
binlog_mdev342
.
test
restart
-
binlog_mdev342
.
test
...
...
mysql-test/suite/binlog/t/binlog_truncate_multi_log.test
View file @
58c293f2
...
@@ -63,6 +63,7 @@ SELECT @@global.gtid_binlog_state;
...
@@ -63,6 +63,7 @@ SELECT @@global.gtid_binlog_state;
#
#
# Server restart
# Server restart
#
#
# sigabrt somewhere here
--
let
$restart_parameters
=
--
init
-
rpl
-
role
=
SLAVE
--
sync
-
binlog
=
1
--
log
-
warnings
=
3
--
let
$restart_parameters
=
--
init
-
rpl
-
role
=
SLAVE
--
sync
-
binlog
=
1
--
log
-
warnings
=
3
--
source
include
/
start_mysqld
.
inc
--
source
include
/
start_mysqld
.
inc
...
...
mysql-test/suite/binlog/t/binlog_truncate_multi_log_unsafe.test
View file @
58c293f2
...
@@ -94,6 +94,7 @@ SELECT @@global.gtid_binlog_state;
...
@@ -94,6 +94,7 @@ SELECT @@global.gtid_binlog_state;
--
error
1
--
error
1
--
exec
$MYSQLD_LAST_CMD
--
init
-
rpl
-
role
=
SLAVE
>>
$MYSQLTEST_VARDIR
/
log
/
mysqld
.
1.
err
2
>&
1
--
exec
$MYSQLD_LAST_CMD
--
init
-
rpl
-
role
=
SLAVE
>>
$MYSQLTEST_VARDIR
/
log
/
mysqld
.
1.
err
2
>&
1
# somewhere below: sigabrt
--
echo
# Normal restart
--
echo
# Normal restart
--
source
include
/
start_mysqld
.
inc
--
source
include
/
start_mysqld
.
inc
...
...
mysql-test/suite/binlog/t/binlog_xa_recover.test
View file @
58c293f2
This diff is collapsed.
Click to expand it.
sql/handler.cc
View file @
58c293f2
...
@@ -2609,6 +2609,7 @@ static void xarecover_do_commit_or_rollback(handlerton *hton,
...
@@ -2609,6 +2609,7 @@ static void xarecover_do_commit_or_rollback(handlerton *hton,
else
else
x
=
*
member
->
full_xid
;
x
=
*
member
->
full_xid
;
// abort();
rc
=
xarecover_decide_to_commit
(
member
,
ptr_commit_max
)
?
rc
=
xarecover_decide_to_commit
(
member
,
ptr_commit_max
)
?
hton
->
commit_by_xid
(
hton
,
&
x
)
:
hton
->
rollback_by_xid
(
hton
,
&
x
);
hton
->
commit_by_xid
(
hton
,
&
x
)
:
hton
->
rollback_by_xid
(
hton
,
&
x
);
...
...
sql/log.cc
View file @
58c293f2
...
@@ -11680,11 +11680,13 @@ int TC_LOG_BINLOG::recover(LOG_INFO *linfo, const char *last_log_name,
...
@@ -11680,11 +11680,13 @@ int TC_LOG_BINLOG::recover(LOG_INFO *linfo, const char *last_log_name,
{
{
if
(
!
binlog_checkpoint_found
)
if
(
!
binlog_checkpoint_found
)
break
;
break
;
DBUG_EXECUTE_IF
(
"xa_recover_expect_master_bin_000004"
,
/*
if
(
0
!=
strcmp
(
"./master-bin.000004"
,
binlog_checkpoint_name
)
&&
DBUG_EXECUTE_IF("xa_recover_expect_master_bin_000004",
0
!=
strcmp
(
".
\\
master-bin.000004"
,
binlog_checkpoint_name
))
if (0 != strcmp("./master-bin.000004", binlog_checkpoint_name) &&
DBUG_SUICIDE
();
0 != strcmp(".\\master-bin.000004", binlog_checkpoint_name))
);
DBUG_SUICIDE();
);
*/
if
(
find_log_pos
(
linfo
,
binlog_checkpoint_name
,
1
))
if
(
find_log_pos
(
linfo
,
binlog_checkpoint_name
,
1
))
{
{
sql_print_error
(
"Binlog file '%s' not found in binlog index, needed "
sql_print_error
(
"Binlog file '%s' not found in binlog index, needed "
...
...
storage/spider/spd_trx.cc
View file @
58c293f2
...
@@ -3287,6 +3287,9 @@ int spider_xa_commit_by_xid(
...
@@ -3287,6 +3287,9 @@ int spider_xa_commit_by_xid(
THD
*
thd
=
current_thd
;
THD
*
thd
=
current_thd
;
DBUG_ENTER
(
"spider_xa_commit_by_xid"
);
DBUG_ENTER
(
"spider_xa_commit_by_xid"
);
/*
abort();
*/
if
(
!
(
trx
=
spider_get_trx
(
thd
,
TRUE
,
&
error_num
)))
if
(
!
(
trx
=
spider_get_trx
(
thd
,
TRUE
,
&
error_num
)))
goto
error_get_trx
;
goto
error_get_trx
;
...
@@ -3309,6 +3312,9 @@ int spider_xa_rollback_by_xid(
...
@@ -3309,6 +3312,9 @@ int spider_xa_rollback_by_xid(
THD
*
thd
=
current_thd
;
THD
*
thd
=
current_thd
;
DBUG_ENTER
(
"spider_xa_rollback_by_xid"
);
DBUG_ENTER
(
"spider_xa_rollback_by_xid"
);
/*
abort();
*/
if
(
!
(
trx
=
spider_get_trx
(
thd
,
TRUE
,
&
error_num
)))
if
(
!
(
trx
=
spider_get_trx
(
thd
,
TRUE
,
&
error_num
)))
goto
error_get_trx
;
goto
error_get_trx
;
...
...
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