diff options
author | Jan Lindström <jplindst@mariadb.org> | 2013-09-26 16:43:49 +0300 |
---|---|---|
committer | Jan Lindström <jplindst@mariadb.org> | 2013-09-26 16:43:49 +0300 |
commit | c72126e043c42ccbc3e0e138dc3aef3950959158 (patch) | |
tree | e716ceeb7a2a7c5e19a681f7a0d120b9d0a98753 /sql/wsrep_hton.cc | |
parent | 77fae5af0065664c3b90eebc4a0dbc4bd48efa3a (diff) | |
download | mariadb-git-c72126e043c42ccbc3e0e138dc3aef3950959158.tar.gz |
Merge revisions 3907--3914 from lp:~codership/codership-mysql/5.5-23
------------------------------------------------------------
revno: 3914 3kB/s |
committer: Vladislav Klyachin <vladislav.klyachin@codership.com>
branch nick: 5.5-23
timestamp: Thu 2013-09-12 15:00:46 +0400
message:
References lp:1217653 - fix index-id evaluation of FOREIGN KEY, when referenced table without PRIMARY KEY
------------------------------------------------------------
revno: 3913
committer: Vladislav Klyachin <vladislav.klyachin@codership.com>
branch nick: 5.5-23
timestamp: Wed 2013-09-11 13:58:02 +0400
message:
References lp:1217653 - fix index-id evaluation of FOREIGN KEY, when referenced table without PRIMARY KEY
------------------------------------------------------------
revno: 3912
committer: Seppo Jaakola <seppo.jaakola@codership.com>
branch nick: wsrep-5.5-23
timestamp: Fri 2013-09-06 13:13:48 +0300
message:
References: lp:1212955 - releasing MDL after failed BEGIN and "SET AUTOCOMMIT"
------------------------------------------------------------
revno: 3911
committer: Seppo Jaakola <seppo.jaakola@codership.com>
branch nick: wsrep-5.5-23
timestamp: Wed 2013-09-04 10:52:31 +0300
message:
References: lp:1123233 - avoiding to set wsrep_seqno_changed for replaying transactions
Note, also missing transactions don't declare seqno_changed anymore. Earlier they would have caused crash at wsrep_cleanup_transaction phase.
------------------------------------------------------------
revno: 3910 [merge]
committer: Vladislav Klyachin <vladislav.klyachin@codership.com>
branch nick: 5.5-23
timestamp: Tue 2013-09-03 15:27:02 +0400
message:
References lp:1049599 - expose desync functionality to the client
------------------------------------------------------------
revno: 3909
committer: Seppo Jaakola <seppo.jaakola@codership.com>
branch nick: wsrep-5.5-23
timestamp: Tue 2013-09-03 09:41:08 +0300
message:
References: lp:1123233 - rollback for transaction which has not appended key information
------------------------------------------------------------
revno: 3908
committer: Vladislav Klyachin <vladislav.klyachin@codership.com>
branch nick: 5.5-23
timestamp: Sun 2013-09-01 13:29:12 +0400
message:
lp:1201893 - fix command for default IP address
------------------------------------------------------------
revno: 3907
committer: Seppo Jaakola <seppo.jaakola@codership.com>
branch nick: wsrep-5.5-23
timestamp: Thu 2013-08-29 12:16:42 +0300
message:
References: lp:1212955 - releasing transactional MDL locks after commit failures (e.g. certification failure).
Diffstat (limited to 'sql/wsrep_hton.cc')
-rw-r--r-- | sql/wsrep_hton.cc | 26 |
1 files changed, 19 insertions, 7 deletions
diff --git a/sql/wsrep_hton.cc b/sql/wsrep_hton.cc index bd934031fc3..3756f54ab48 100644 --- a/sql/wsrep_hton.cc +++ b/sql/wsrep_hton.cc @@ -331,9 +331,17 @@ wsrep_run_wsrep_commit( } if (WSREP_UNDEFINED_TRX_ID == thd->wsrep_trx_handle.trx_id) { - WSREP_WARN("SQL statement was ineffective: %s\n => Skipping replication", thd->query()); - } - else if (!rcode) + WSREP_WARN("SQL statement was ineffective, THD: %lu, buf: %d\n" + "QUERY: %s\n" + " => Skipping replication", + thd->thread_id, data_len, thd->query()); + if (wsrep_debug) + { + wsrep_write_rbr_buf(thd, rbr_data, data_len); + } + rcode = WSREP_TRX_FAIL; + } + else if (!rcode) { rcode = wsrep->pre_commit( wsrep, @@ -343,13 +351,14 @@ wsrep_run_wsrep_commit( data_len, (thd->wsrep_PA_safe) ? WSREP_FLAG_PA_SAFE : 0ULL, &thd->wsrep_trx_seqno); - if (rcode == WSREP_TRX_MISSING) { + switch (rcode) { + case WSREP_TRX_MISSING: WSREP_WARN("Transaction missing in provider, thd: %ld, SQL: %s", thd->thread_id, thd->query()); wsrep_write_rbr_buf(thd, rbr_data, data_len); - rcode = WSREP_OK; - } else if (rcode == WSREP_BF_ABORT) { + break; + case WSREP_BF_ABORT: mysql_mutex_lock(&thd->LOCK_wsrep_thd); thd->wsrep_conflict_state = MUST_REPLAY; mysql_mutex_unlock(&thd->LOCK_wsrep_thd); @@ -358,8 +367,11 @@ wsrep_run_wsrep_commit( WSREP_DEBUG("replaying increased: %d, thd: %lu", wsrep_replaying, thd->thread_id); mysql_mutex_unlock(&LOCK_wsrep_replaying); + break; + default: + thd->wsrep_seqno_changed = true; + break; } - thd->wsrep_seqno_changed = true; } else { WSREP_ERROR("I/O error reading from thd's binlog iocache: " "errno=%d, io cache code=%d", my_errno, cache->error); |