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

feat: add resilience to initial wallet connect #6527

Conversation

hansieodendaal
Copy link
Contributor

@hansieodendaal hansieodendaal commented Sep 4, 2024

Description

Added resilience to the initial wallet connection in cases where a custom base node has not been set, where the wallet will try all base nodes or all seeds it knows of and not only one it chose at random.

Motivation and Context

Wallets would try indefinitely to establish an initial connection to an offline peer.

How Has This Been Tested?

  • Added a new unit test.
  • System-level testing
    Start a wallet with multiple custom seed nodes where only one is online. Shut down the wallet after the established connection, delete its peer db, and redo. Do this multiple times. Confirm that the wallet establishes a connection every time.

What process can a PR reviewer use to test or verify this change?

Review code changes

Breaking Changes

  • None
  • Requires data directory on base node to be deleted
  • Requires hard fork
  • Other - Please specify

@hansieodendaal hansieodendaal requested a review from a team as a code owner September 4, 2024 14:24
@ghpbot-tari-project ghpbot-tari-project added P-acks_required Process - Requires more ACKs or utACKs P-reviews_required Process - Requires a review from a lead maintainer to be merged labels Sep 4, 2024
Copy link

github-actions bot commented Sep 4, 2024

Test Results (CI)

    3 files    129 suites   39m 29s ⏱️
1 323 tests 1 323 ✅ 0 💤 0 ❌
3 967 runs  3 967 ✅ 0 💤 0 ❌

Results for commit 4ce5566.

♻️ This comment has been updated with latest results.

Copy link

github-actions bot commented Sep 4, 2024

Test Results (Integration tests)

 2 files  11 suites   17m 9s ⏱️
36 tests 35 ✅ 0 💤 1 ❌
37 runs  36 ✅ 0 💤 1 ❌

For more details on these failures, see this check.

Results for commit 4ce5566.

♻️ This comment has been updated with latest results.

@hansieodendaal hansieodendaal marked this pull request as draft September 5, 2024 03:54
@hansieodendaal hansieodendaal force-pushed the ho_wallet_connect_at_startup branch 4 times, most recently from 694aca7 to 3dc8b37 Compare September 9, 2024 07:19
@hansieodendaal hansieodendaal force-pushed the ho_wallet_connect_at_startup branch 4 times, most recently from 3b4fd29 to 89e2e82 Compare September 18, 2024 15:27
Added resiliance to initial wallet connect, where the wallet will try all base
nodes or all seeds it knows of and not only one it chose at random.
@hansieodendaal hansieodendaal force-pushed the ho_wallet_connect_at_startup branch from 89e2e82 to 4ce5566 Compare September 18, 2024 16:25
@hansieodendaal hansieodendaal marked this pull request as ready for review September 18, 2024 16:26
Copy link
Collaborator

@SWvheerden SWvheerden left a comment

Choose a reason for hiding this comment

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

Looks good, just 1 comment

applications/minotari_console_wallet/src/init/mod.rs Outdated Show resolved Hide resolved
@SWvheerden SWvheerden merged commit 6b5ef7d into tari-project:development Sep 20, 2024
13 of 15 checks passed
@hansieodendaal hansieodendaal deleted the ho_wallet_connect_at_startup branch September 25, 2024 07:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P-acks_required Process - Requires more ACKs or utACKs P-reviews_required Process - Requires a review from a lead maintainer to be merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants