mirror of
https://github.com/codership/wsrep-lib.git
synced 2025-07-28 20:02:00 +03:00
* Renamed client service rollback() to bf_rollback() to better
describe its purpose. * Raise deadlock error for BF aborted transaction in after_statement() call if the error is not set yet.
This commit is contained in:
@ -81,10 +81,16 @@ namespace wsrep
|
||||
// Rollback
|
||||
//
|
||||
/**
|
||||
* Roll back all transactions which are currently active
|
||||
* in the client session.
|
||||
* Perform brute force rollback.
|
||||
*
|
||||
* This method may be called from two contexts, either from
|
||||
* client state methods when the BF abort condition is detected,
|
||||
* or from the background rollbacker thread. The task for this
|
||||
* method is to release all reasources held by the client
|
||||
* after BF abort so that the high priority thread can continue
|
||||
* applying.
|
||||
*/
|
||||
virtual int rollback() = 0;
|
||||
virtual int bf_rollback() = 0;
|
||||
|
||||
//
|
||||
// Interface to global server state
|
||||
|
@ -267,6 +267,7 @@ namespace wsrep
|
||||
*/
|
||||
int start_transaction(const wsrep::transaction_id& id)
|
||||
{
|
||||
wsrep::unique_lock<wsrep::mutex> lock(mutex_);
|
||||
assert(state_ == s_exec);
|
||||
return transaction_.start_transaction(id);
|
||||
}
|
||||
@ -327,6 +328,7 @@ namespace wsrep
|
||||
int start_transaction(const wsrep::ws_handle& wsh,
|
||||
const wsrep::ws_meta& meta)
|
||||
{
|
||||
wsrep::unique_lock<wsrep::mutex> lock(mutex_);
|
||||
assert(mode_ == m_high_priority);
|
||||
return transaction_.start_transaction(wsh, meta);
|
||||
}
|
||||
|
Reference in New Issue
Block a user