diff --git a/conanfile.py b/conanfile.py index ad9576b5..83af400a 100644 --- a/conanfile.py +++ b/conanfile.py @@ -10,7 +10,7 @@ class HomeObjectConan(ConanFile): name = "homeobject" - version = "4.2.3" + version = "4.2.4" homepage = "https://github.com/eBay/HomeObject" description = "Blob Store built on HomeStore" diff --git a/src/lib/homestore_backend/replication_state_machine.cpp b/src/lib/homestore_backend/replication_state_machine.cpp index bd8f5d6b..3ae6cfee 100644 --- a/src/lib/homestore_backend/replication_state_machine.cpp +++ b/src/lib/homestore_backend/replication_state_machine.cpp @@ -212,21 +212,14 @@ ReplicationStateMachine::get_blk_alloc_hints(sisl::blob const& header, uint32_t switch (msg_header->msg_type) { case ReplicationMessageType::CREATE_SHARD_MSG: case ReplicationMessageType::SEAL_SHARD_MSG: { - if (data_size == 0) { - // New log-only format: should not reach here, but handle gracefully. - LOGW("get_blk_alloc_hints called for log-only shard message type={}, shard={}, pg={}", msg_header->msg_type, - msg_header->shard_id, msg_header->pg_id); - return homestore::blk_alloc_hints{}; - } else { - // Old format: shard message carried shard header/footer data blocks. Return committed_blk_id - // so HomeStore skips block allocation and data write. Shard on_commit will ignore pbas. - homestore::blk_alloc_hints hints; - hints.committed_blk_id = HSHomeObject::tombstone_pbas; - LOGW("get_blk_alloc_hints called for old shard message type={}, shard={}, pg={}, return committed_blk hint " - "to skip blk allocation", - msg_header->msg_type, msg_header->shard_id, msg_header->pg_id); - return hints; - } + // Old format: shard message carried shard header/footer data blocks. Return committed_blk_id + // so HomeStore skips block allocation and data write. Shard on_commit will ignore pbas. + homestore::blk_alloc_hints hints; + hints.committed_blk_id = HSHomeObject::tombstone_pbas; + LOGW("get_blk_alloc_hints called for old shard message type={}, shard={}, pg={}, return committed_blk hint " + "to skip blk allocation", + msg_header->msg_type, msg_header->shard_id, msg_header->pg_id); + return hints; } case ReplicationMessageType::PUT_BLOB_MSG: