Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: fix test_network_disconnect_during_migration #4378

Merged
merged 1 commit into from
Dec 30, 2024

Conversation

BorysTheDev
Copy link
Contributor

fixes: #4344
problem: we waited up to 10 seconds for the migration to be restarted but the default timeout for migration restart was 30 seconds

@@ -1433,8 +1433,7 @@ async def test_migration_with_key_ttl(df_factory):
assert await nodes[1].client.execute_command("stick k_sticky") == 0


@pytest.mark.skip("Flaky test")
@dfly_args({"proactor_threads": 4, "cluster_mode": "yes"})
@dfly_args({"proactor_threads": 4, "cluster_mode": "yes", "migration_finalization_timeout_ms": 5})
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you change here the migration_finalization_timeout_ms default
in this test we check that when we cancel the migration due to disconnect we are restarting the migration again and we wait for the sync status
please explain how finalization timeout affect this and why?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if we cancel the migration during finalization we should wait until the timeout is ended, and to prevent 30 seconds of waiting I have changed it to 5

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why dont we break on waiting the finalization? because if the connection is closed so we should return with error while waiting for the migration finalization.

Copy link
Contributor Author

@BorysTheDev BorysTheDev Dec 30, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we try to reconnect until the timeout happens, but the target node waits for LSN for the previous attempt

@BorysTheDev BorysTheDev merged commit b753253 into main Dec 30, 2024
9 checks passed
@BorysTheDev BorysTheDev deleted the fix_test_network_disconnect_during_migration branch December 30, 2024 12:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

test_network_disconnect_during_migration is flaky
2 participants