1
0
mirror of https://github.com/codership/wsrep-lib.git synced 2025-07-28 20:02:00 +03:00

Introduced adopt_transaction() for storage_service interface

A SR transaction must be adopted by a storage service instance
running in background rollbacker thread while it is aborting a
SR transaction.
This commit is contained in:
Teemu Ollakka
2018-07-13 15:36:27 +03:00
parent 22d7a31d81
commit 4cfb9b6413
10 changed files with 43 additions and 32 deletions

View File

@ -28,11 +28,18 @@ wsrep::mock_storage_service::~mock_storage_service()
client_state_.cleanup();
}
int wsrep::mock_storage_service::start_transaction(const wsrep::ws_handle& ws_handle)
int wsrep::mock_storage_service::start_transaction(
const wsrep::ws_handle& ws_handle)
{
return client_state_.start_transaction(ws_handle.transaction_id());
}
void wsrep::mock_storage_service::adopt_transaction(
const wsrep::transaction& transaction)
{
client_state_.adopt_transaction(transaction);
}
int wsrep::mock_storage_service::commit(const wsrep::ws_handle& ws_handle,
const wsrep::ws_meta& ws_meta)
{