diff --git a/conanfile.py b/conanfile.py index d6fd6f6f1..606d1a6ea 100644 --- a/conanfile.py +++ b/conanfile.py @@ -9,7 +9,7 @@ class HomestoreConan(ConanFile): name = "homestore" - version = "6.5.16" + version = "6.5.17" homepage = "https://github.com/eBay/Homestore" description = "HomeStore Storage Engine" diff --git a/src/lib/replication/repl_dev/common.cpp b/src/lib/replication/repl_dev/common.cpp index 4fcbb0f4e..1c2a8c560 100644 --- a/src/lib/replication/repl_dev/common.cpp +++ b/src/lib/replication/repl_dev/common.cpp @@ -164,15 +164,18 @@ bool repl_req_ctx::add_state_if_not_already(repl_req_state_t s) { void repl_req_ctx::clear() { m_header = sisl::blob{}; m_key = sisl::blob{}; - release_data(); m_pkts.clear(); } +// FIXME: Use lock to avoid concurrent release of data. void repl_req_ctx::release_data() { m_data = nullptr; // explicitly clear m_buf_for_unaligned_data as unaligned pushdata/fetchdata will be saved here m_buf_for_unaligned_data = sisl::io_blob_safe{}; if (m_pushed_data) { + LOGTRACEMOD(replication, "m_pushed_data addr={}, m_rkey={}, m_lsn={}", + static_cast(m_pushed_data.get()), + m_rkey.to_string(), m_lsn); m_pushed_data->send_response(); m_pushed_data = nullptr; } diff --git a/src/lib/replication/repl_dev/raft_repl_dev.cpp b/src/lib/replication/repl_dev/raft_repl_dev.cpp index 7b4a407cb..2d93c4070 100644 --- a/src/lib/replication/repl_dev/raft_repl_dev.cpp +++ b/src/lib/replication/repl_dev/raft_repl_dev.cpp @@ -453,9 +453,9 @@ void RaftReplDev::on_push_data_received(intrusive< sisl::GenericRpcData >& rpc_d RD_DBG_ASSERT(false, "Error in writing data, error_code={}", err.value()); handle_error(rreq, ReplServiceError::DRIVE_WRITE_ERROR); } else { + rreq->release_data(); rreq->add_state(repl_req_state_t::DATA_WRITTEN); rreq->m_data_written_promise.setValue(); - rreq->release_data(); const auto data_log_diff_us = push_data_rcv_time.time_since_epoch().count() > rreq->created_time().time_since_epoch().count() ? get_elapsed_time_us(rreq->created_time(), push_data_rcv_time) @@ -872,9 +872,9 @@ void RaftReplDev::handle_fetch_data_response(sisl::GenericClientResponse respons RD_REL_ASSERT(!err, "Error in writing data"); // TODO: Find a way to return error to the Listener + rreq->release_data(); rreq->add_state(repl_req_state_t::DATA_WRITTEN); rreq->m_data_written_promise.setValue(); - rreq->release_data(); RD_LOGD("Data Channel: Data Write completed rreq=[{}], data_write_latency_us={}, " "total_write_latency_us={}, write_num_pieces={}",