mirror of
https://github.com/codership/wsrep-lib.git
synced 2025-07-28 20:02:00 +03:00
Added a separate call to notify the client thread about completion
of background rollback. The separate call is necessary as all of the resources may not have been released before the execution reaches after_rollback() call and background rollbacker needs to notify the client thread after all is complete.
This commit is contained in:
@ -382,6 +382,18 @@ namespace wsrep
|
||||
state_ == s_quitting);
|
||||
return transaction_.after_rollback();
|
||||
}
|
||||
|
||||
/**
|
||||
* This method should be called by the background rollbacker
|
||||
* thread after the rollback is complete. This will allow
|
||||
* the client to proceed with command execution.
|
||||
*/
|
||||
void sync_rollback_complete()
|
||||
{
|
||||
assert(state_ == s_idle && mode_ == m_replicating &&
|
||||
transaction_.state() == wsrep::transaction::s_aborted);
|
||||
cond_.notify_all();
|
||||
}
|
||||
/** @} */
|
||||
|
||||
//
|
||||
|
Reference in New Issue
Block a user