mirror of
https://github.com/codership/wsrep-lib.git
synced 2025-07-21 12:22:06 +03:00
Support recovery of XA transactions
* Add method `restore_prepared_transaction` to `client_state` class which restores a transaction state from storage given its xid. * Add method `commit_or_rollback_by_xid` to terminate prepared XA transactions by xid. * Make sure that transactions in prepared state are not rolled back when their master fails/partitions away.
This commit is contained in:
@ -209,7 +209,12 @@ namespace
|
||||
: ws_meta_(ws_meta)
|
||||
, trx_meta_()
|
||||
, flags_(flags)
|
||||
{ }
|
||||
{
|
||||
std::memcpy(trx_meta_.stid.node.data, ws_meta.server_id().data(),
|
||||
sizeof(trx_meta_.stid.node.data));
|
||||
trx_meta_.stid.conn = ws_meta.client_id().get();
|
||||
trx_meta_.stid.trx = ws_meta.transaction_id().get();
|
||||
}
|
||||
|
||||
~mutable_ws_meta()
|
||||
{
|
||||
|
Reference in New Issue
Block a user