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
1d15300b
Commit
1d15300b
authored
May 02, 2023
by
Oleksandr Byelkin
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '10.4' into bb-10.4-release
parents
edd0b03e
c6ef9b1c
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
73 additions
and
7 deletions
+73
-7
mysql-test/suite/galera/r/galera_var_retry_autocommit.result
mysql-test/suite/galera/r/galera_var_retry_autocommit.result
+11
-1
mysql-test/suite/galera/t/galera_var_retry_autocommit.test
mysql-test/suite/galera/t/galera_var_retry_autocommit.test
+18
-1
mysql-test/suite/galera_sr/r/MDEV-30838.result
mysql-test/suite/galera_sr/r/MDEV-30838.result
+15
-0
mysql-test/suite/galera_sr/t/MDEV-30838.test
mysql-test/suite/galera_sr/t/MDEV-30838.test
+18
-0
sql/wsrep_schema.cc
sql/wsrep_schema.cc
+2
-3
sql/wsrep_thd.h
sql/wsrep_thd.h
+8
-1
wsrep-lib
wsrep-lib
+1
-1
No files found.
mysql-test/suite/galera/r/galera_var_retry_autocommit.result
View file @
1d15300b
...
...
@@ -20,17 +20,25 @@ DROP TABLE t1;
connection node_1;
CREATE TABLE t1 (f1 INTEGER PRIMARY KEY) ENGINE=InnoDB;
SET SESSION wsrep_retry_autocommit = 1;
SET GLOBAL debug_dbug = '+d,sync.wsrep_retry_autocommit';
SET DEBUG_SYNC = 'wsrep_before_certification SIGNAL before_cert WAIT_FOR continue';
INSERT INTO t1 (f1) VALUES (3);
connection node_1a;
SET DEBUG_SYNC = 'now WAIT_FOR before_cert';
connection node_2;
TRUNCATE TABLE t1;
connection node_1;
connection node_1a;
SET DEBUG_SYNC = 'now WAIT_FOR wsrep_retry_autocommit_reached';
SELECT COUNT(*) FROM t1;
COUNT(*)
0
SET DEBUG_SYNC = 'now SIGNAL wsrep_retry_autocommit_continue';
connection node_1;
SELECT COUNT(*) FROM t1;
COUNT(*)
1
SET DEBUG_SYNC = 'RESET';
SET GLOBAL debug_dbug = NULL;
DROP TABLE t1;
connection node_1;
CREATE TABLE t1 (f1 INTEGER PRIMARY KEY) ENGINE=InnoDB;
...
...
@@ -64,6 +72,8 @@ SET SESSION wsrep_retry_autocommit = 64;
SET GLOBAL debug_dbug = '+d,sync.wsrep_retry_autocommit';
SET DEBUG_SYNC = 'wsrep_before_certification SIGNAL before_cert WAIT_FOR continue EXECUTE 64';
INSERT INTO t1 VALUES (5);
connection node_2;
connection node_1;
connection node_1;
SELECT COUNT(*) FROM t1;
COUNT(*)
...
...
mysql-test/suite/galera/t/galera_var_retry_autocommit.test
View file @
1d15300b
...
...
@@ -25,6 +25,8 @@ SET DEBUG_SYNC = 'wsrep_before_certification SIGNAL before_cert WAIT_FOR continu
SET
DEBUG_SYNC
=
'now WAIT_FOR before_cert'
;
--
connection
node_2
--
let
$wait_condition
=
SELECT
count
(
*
)
=
1
FROM
information_schema
.
TABLES
WHERE
TABLE_SCHEMA
=
'test'
AND
TABLE_NAME
=
't1'
--
source
include
/
wait_condition
.
inc
TRUNCATE
TABLE
t1
;
--
connection
node_1
...
...
@@ -44,6 +46,7 @@ DROP TABLE t1;
CREATE
TABLE
t1
(
f1
INTEGER
PRIMARY
KEY
)
ENGINE
=
InnoDB
;
SET
SESSION
wsrep_retry_autocommit
=
1
;
SET
GLOBAL
debug_dbug
=
'+d,sync.wsrep_retry_autocommit'
;
SET
DEBUG_SYNC
=
'wsrep_before_certification SIGNAL before_cert WAIT_FOR continue'
;
--
send
INSERT
INTO
t1
(
f1
)
VALUES
(
3
)
...
...
@@ -51,14 +54,21 @@ SET DEBUG_SYNC = 'wsrep_before_certification SIGNAL before_cert WAIT_FOR continu
SET
DEBUG_SYNC
=
'now WAIT_FOR before_cert'
;
--
connection
node_2
--
let
$wait_condition
=
SELECT
count
(
*
)
=
1
FROM
information_schema
.
TABLES
WHERE
TABLE_SCHEMA
=
'test'
AND
TABLE_NAME
=
't1'
--
source
include
/
wait_condition
.
inc
TRUNCATE
TABLE
t1
;
--
connection
node_1a
SET
DEBUG_SYNC
=
'now WAIT_FOR wsrep_retry_autocommit_reached'
;
SELECT
COUNT
(
*
)
FROM
t1
;
SET
DEBUG_SYNC
=
'now SIGNAL wsrep_retry_autocommit_continue'
;
--
connection
node_1
--
error
0
,
ER_LOCK_DEADLOCK
--
reap
SELECT
COUNT
(
*
)
FROM
t1
;
SET
DEBUG_SYNC
=
'RESET'
;
SET
GLOBAL
debug_dbug
=
NULL
;
DROP
TABLE
t1
;
...
...
@@ -79,6 +89,8 @@ SET DEBUG_SYNC = 'wsrep_before_certification SIGNAL before_cert WAIT_FOR continu
SET
DEBUG_SYNC
=
'now WAIT_FOR before_cert'
;
--
connection
node_2
--
let
$wait_condition
=
SELECT
count
(
*
)
=
1
FROM
information_schema
.
TABLES
WHERE
TABLE_SCHEMA
=
'test'
AND
TABLE_NAME
=
't1'
--
source
include
/
wait_condition
.
inc
TRUNCATE
TABLE
t1
;
--
connection
node_1a
...
...
@@ -114,6 +126,11 @@ SET DEBUG_SYNC = 'wsrep_before_certification SIGNAL before_cert WAIT_FOR continu
--
send
INSERT
INTO
t1
VALUES
(
5
)
--
connection
node_2
--
let
$wait_condition
=
SELECT
count
(
*
)
=
1
FROM
information_schema
.
TABLES
WHERE
TABLE_SCHEMA
=
'test'
AND
TABLE_NAME
=
't1'
--
source
include
/
wait_condition
.
inc
--
connection
node_1
--
disable_query_log
--
disable_result_log
--
let
$count
=
64
...
...
mysql-test/suite/galera_sr/r/MDEV-30838.result
0 → 100644
View file @
1d15300b
connection node_2;
connection node_1;
CREATE TABLE t1 (f1 INTEGER PRIMARY KEY);
SET SESSION wsrep_trx_fragment_size=1;
START TRANSACTION;
INSERT INTO t1 VALUES(1);
SET debug_dbug='+d,ib_create_table_fail_too_many_trx';
INSERT INTO t1 VALUES(2);
ERROR HY000: Error while appending streaming replication fragment
COMMIT;
SELECT * FROM t1;
f1
SET debug_dbug='-d,ib_create_table_fail_too_many_trx';
DROP TABLE t1;
CALL mtr.add_suppression("Error writing into mysql.wsrep_streaming_log: 177");
mysql-test/suite/galera_sr/t/MDEV-30838.test
0 → 100644
View file @
1d15300b
#
# MDEV-30838 - Assertion `m_thd == _current_thd()' failed in
# virtual int Wsrep_client_service::bf_rollback()
#
--
source
include
/
galera_cluster
.
inc
--
source
include
/
have_debug_sync
.
inc
CREATE
TABLE
t1
(
f1
INTEGER
PRIMARY
KEY
);
SET
SESSION
wsrep_trx_fragment_size
=
1
;
START
TRANSACTION
;
INSERT
INTO
t1
VALUES
(
1
);
SET
debug_dbug
=
'+d,ib_create_table_fail_too_many_trx'
;
--
error
ER_ERROR_DURING_COMMIT
INSERT
INTO
t1
VALUES
(
2
);
COMMIT
;
SELECT
*
FROM
t1
;
SET
debug_dbug
=
'-d,ib_create_table_fail_too_many_trx'
;
DROP
TABLE
t1
;
CALL
mtr
.
add_suppression
(
"Error writing into mysql.wsrep_streaming_log: 177"
);
sql/wsrep_schema.cc
View file @
1d15300b
...
...
@@ -991,10 +991,9 @@ int Wsrep_schema::append_fragment(THD* thd,
Wsrep_schema_impl
::
store
(
frag_table
,
3
,
flags
);
Wsrep_schema_impl
::
store
(
frag_table
,
4
,
data
.
data
(),
data
.
size
());
int
error
;
if
((
error
=
Wsrep_schema_impl
::
insert
(
frag_table
)))
{
WSREP_ERROR
(
"Failed to write to frag table: %d"
,
error
);
if
(
Wsrep_schema_impl
::
insert
(
frag_table
))
{
trans_rollback_stmt
(
thd
);
close_thread_tables
(
thd
);
thd
->
lex
->
restore_backup_query_tables_list
(
&
query_tables_list_backup
);
DBUG_RETURN
(
1
);
}
...
...
sql/wsrep_thd.h
View file @
1d15300b
...
...
@@ -228,7 +228,14 @@ static inline void wsrep_override_error(THD* thd,
break
;
case
wsrep
:
:
e_append_fragment_error
:
/* TODO: Figure out better error number */
wsrep_override_error
(
thd
,
ER_ERROR_DURING_COMMIT
,
0
,
status
);
if
(
status
)
wsrep_override_error
(
thd
,
ER_ERROR_DURING_COMMIT
,
"Error while appending streaming replication fragment"
"(provider status: %s)"
,
wsrep
::
provider
::
to_string
(
status
).
c_str
());
else
wsrep_override_error
(
thd
,
ER_ERROR_DURING_COMMIT
,
"Error while appending streaming replication fragment"
);
break
;
case
wsrep
:
:
e_not_supported_error
:
wsrep_override_error
(
thd
,
ER_NOT_SUPPORTED_YET
);
...
...
wsrep-lib
@
4951c383
Subproject commit
275a0af8c5b92f0ee33cfe9e23f3db5f59b56e9d
Subproject commit
4951c38357737d568b554402bc5b6abe88a38fe1
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