mirror of
https://github.com/codership/wsrep-lib.git
synced 2025-07-30 07:23:07 +03:00
TOI replicating and applying codepaths
This commit is contained in:
@ -6,15 +6,23 @@
|
||||
#include "mock_client_state.hpp"
|
||||
|
||||
|
||||
int wsrep::mock_client_service::apply(
|
||||
int wsrep::mock_client_service::apply_write_set(
|
||||
const wsrep::const_buffer&)
|
||||
|
||||
{
|
||||
assert(client_state_.toi_meta().seqno().is_undefined());
|
||||
assert(client_state_.transaction().state() == wsrep::transaction::s_executing ||
|
||||
client_state_.transaction().state() == wsrep::transaction::s_replaying);
|
||||
return (fail_next_applying_ ? 1 : 0);
|
||||
}
|
||||
|
||||
int wsrep::mock_client_service::apply_toi(const wsrep::const_buffer&)
|
||||
{
|
||||
assert(client_state_.transaction().active() == false);
|
||||
assert(client_state_.toi_meta().seqno().is_undefined() == false);
|
||||
return (fail_next_toi_ ? 1 : 0);
|
||||
}
|
||||
|
||||
int wsrep::mock_client_service::commit(
|
||||
const wsrep::ws_handle&, const wsrep::ws_meta&)
|
||||
{
|
||||
|
Reference in New Issue
Block a user