Skip to content

Commit

Permalink
correct
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanmorozov333 committed Jan 7, 2025
1 parent b8b8174 commit 7ce8a4a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ydb/core/tx/columnshard/columnshard__write.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,9 @@ class TCommitOperation {
auto& lock = evWrite.Record.GetLocks().GetLocks()[0];
SendingShards = std::set<ui64>(locks.GetSendingShards().begin(), locks.GetSendingShards().end());
ReceivingShards = std::set<ui64>(locks.GetReceivingShards().begin(), locks.GetReceivingShards().end());
if (SendingShards.empty() != ReceivingShards.empty()) {
return TConclusionStatus::Fail("incorrect synchronization data (send/receiving lists)");
}
if (ReceivingShards.size() && SendingShards.size()) {
if (!locks.HasArbiterColumnShard()) {
ArbiterColumnShard = *ReceivingShards.begin();
Expand All @@ -326,8 +329,6 @@ class TCommitOperation {
return TConclusionStatus::Fail("shard is incorrect for sending/receiving lists");
}
}
} else {
AFL_VERIFY(!SendingShards.size() && !ReceivingShards.size());
}

TxId = evWrite.Record.GetTxId();
Expand Down

0 comments on commit 7ce8a4a

Please sign in to comment.