diff options
author | Daniele Sciascia <daniele.sciascia@galeracluster.com> | 2019-10-24 13:05:33 +0200 |
---|---|---|
committer | Jan Lindström <jan.lindstrom@mariadb.com> | 2019-10-24 14:05:32 +0300 |
commit | 2b5f4b3ed68585b310b7ebede474928ff90d9aa2 (patch) | |
tree | 26741beb4fc5b42b8afdc6a3582f36932c8e6288 /sql/wsrep_client_service.cc | |
parent | 82f22d2f2538fd53eae071a3694c7c998df4d387 (diff) | |
download | mariadb-git-2b5f4b3ed68585b310b7ebede474928ff90d9aa2.tar.gz |
MDEV-17099 Preliminary changes for Galera XA support (#1401)
Update wsrep-lib, and adapt to wsrep-lib interface changes.
Diffstat (limited to 'sql/wsrep_client_service.cc')
-rw-r--r-- | sql/wsrep_client_service.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sql/wsrep_client_service.cc b/sql/wsrep_client_service.cc index 5f73f9f714f..20bb7748a95 100644 --- a/sql/wsrep_client_service.cc +++ b/sql/wsrep_client_service.cc @@ -138,7 +138,8 @@ void Wsrep_client_service::cleanup_transaction() } -int Wsrep_client_service::prepare_fragment_for_replication(wsrep::mutable_buffer& buffer) +int Wsrep_client_service::prepare_fragment_for_replication( + wsrep::mutable_buffer& buffer, size_t& log_position) { DBUG_ASSERT(m_thd == current_thd); THD* thd= m_thd; @@ -152,7 +153,7 @@ int Wsrep_client_service::prepare_fragment_for_replication(wsrep::mutable_buffer } const my_off_t saved_pos(my_b_tell(cache)); - if (reinit_io_cache(cache, READ_CACHE, thd->wsrep_sr().bytes_certified(), 0, 0)) + if (reinit_io_cache(cache, READ_CACHE, thd->wsrep_sr().log_position(), 0, 0)) { DBUG_RETURN(1); } @@ -186,6 +187,7 @@ int Wsrep_client_service::prepare_fragment_for_replication(wsrep::mutable_buffer while (cache->file >= 0 && (length= my_b_fill(cache))); } DBUG_ASSERT(total_length == buffer.size()); + log_position= saved_pos; cleanup: if (reinit_io_cache(cache, WRITE_CACHE, saved_pos, 0, 0)) { |