summaryrefslogtreecommitdiff
path: root/sql/wsrep_hton.cc
diff options
context:
space:
mode:
authorOleksandr Byelkin <sanja@mariadb.com>2019-12-04 17:46:28 +0100
committerOleksandr Byelkin <sanja@mariadb.com>2019-12-04 17:46:28 +0100
commit008ee867a4cc80e079bd2a8b7f8c8543d80c31f1 (patch)
tree9a971dca67c9edeabeb655b2275aea4b76729333 /sql/wsrep_hton.cc
parent670c9a3a182cfc3a75bc8ed847cadb2931aaaec4 (diff)
parentc9b9eb331570704d020fcc7c7894f19febe7f26d (diff)
downloadmariadb-git-008ee867a4cc80e079bd2a8b7f8c8543d80c31f1.tar.gz
Merge branch '10.2' into 10.3
Diffstat (limited to 'sql/wsrep_hton.cc')
-rw-r--r--sql/wsrep_hton.cc20
1 files changed, 18 insertions, 2 deletions
diff --git a/sql/wsrep_hton.cc b/sql/wsrep_hton.cc
index f84aa5b2e84..1feb46ecdaf 100644
--- a/sql/wsrep_hton.cc
+++ b/sql/wsrep_hton.cc
@@ -488,11 +488,27 @@ wsrep_run_wsrep_commit(THD *thd, bool all)
if (WSREP_UNDEFINED_TRX_ID == thd->wsrep_ws_handle.trx_id)
{
- WSREP_WARN("SQL statement was ineffective thd: %lld buf: %zu\n"
+ /*
+ Async replication slave may have applied some non-innodb workload,
+ and then has written replication "meta data" into gtid_slave_pos
+ innodb table. Writes to gtid_slave_pos must not be replicated,
+ but this activity has caused that innodb hton is registered for this
+ transaction, but no wsrep keys have been appended.
+ We enter in this code path, because IO cache has events for non-innodb
+ tables.
+ => we should not treat it an error if trx is not introduced for provider
+ */
+ if (thd->system_thread == SYSTEM_THREAD_SLAVE_SQL)
+ {
+ WSREP_DEBUG("skipping wsrep replication for async slave, error not raised");
+ DBUG_RETURN(WSREP_TRX_OK);
+ }
+
+ WSREP_WARN("SQL statement was ineffective thd: %llu buf: %zu\n"
"schema: %s \n"
"QUERY: %s\n"
" => Skipping replication",
- (longlong) thd->thread_id, data_len,
+ (ulonglong) thd->thread_id, data_len,
thd->get_db(), thd->query());
rcode = WSREP_TRX_FAIL;
}