fix: make pause all for migration finalization (#4897)

This commit is contained in:
Borys 2025-04-07 12:53:29 +03:00 committed by GitHub
parent 3a0830150e
commit 2729332a0f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 4 additions and 13 deletions

View file

@ -309,7 +309,7 @@ bool OutgoingMigration::FinalizeMigration(long attempt) {
auto is_pause_in_progress = [&is_block_active] { return is_block_active; };
auto pause_fb_opt =
dfly::Pause(server_family_->GetNonPriviligedListeners(), &namespaces->GetDefaultNamespace(),
nullptr, ClientPause::WRITE, is_pause_in_progress);
nullptr, ClientPause::ALL, is_pause_in_progress);
if (!pause_fb_opt) {
auto err = absl::StrCat("Migration finalization time out ", cf_->MyID(), " : ",

View file

@ -191,7 +191,7 @@ io::Result<journal::ParsedEntry> JournalReader::ReadEntry() {
entry.dbid = dbid_;
entry.opcode = opcode;
if (opcode == journal::Op::PING || opcode == journal::Op::FIN) {
if (opcode == journal::Op::PING) {
return entry;
}

View file

@ -55,7 +55,6 @@ void TransactionData::AddEntry(journal::ParsedEntry&& entry) {
lsn = entry.lsn;
return;
case journal::Op::PING:
case journal::Op::FIN:
return;
case journal::Op::EXPIRED:
case journal::Op::COMMAND:

View file

@ -13,15 +13,7 @@
namespace dfly {
namespace journal {
enum class Op : uint8_t {
NOOP = 0,
SELECT = 6,
EXPIRED = 9,
COMMAND = 10,
PING = 13,
FIN = 14,
LSN = 15
};
enum class Op : uint8_t { NOOP = 0, SELECT = 6, EXPIRED = 9, COMMAND = 10, PING = 13, LSN = 15 };
struct EntryBase {
TxId txid;

View file

@ -2725,7 +2725,7 @@ async def test_migration_timeout_on_sync(df_factory: DflyInstanceFactory, df_see
port=next(next_port),
admin_port=next(next_port),
replication_timeout=3000,
vmodule="outgoing_slot_migration=2,cluster_family=2,incoming_slot_migration=2,main_service=2",
vmodule="outgoing_slot_migration=2,cluster_family=2,incoming_slot_migration=2",
)
for i in range(2)
]