Skip to content

Prefer MASQUE relay addresses for client P2P#52

Merged
jacderida merged 8 commits intomainfrom
mick/always-masque-relay-rebased
Apr 22, 2026
Merged

Prefer MASQUE relay addresses for client P2P#52
jacderida merged 8 commits intomainfrom
mick/always-masque-relay-rebased

Conversation

@mickvandijke
Copy link
Copy Markdown
Contributor

Summary

  • Use relay-sorted addresses in find_closest_peers so chunk store / quote collection try reachable relay addresses first instead of unreachable NATted addresses.
  • Apply IPDiversityConfig::permissive unconditionally to client P2P nodes (both ant-cli and ant-core::Network::new) — clients aren't Sybil targets and diversity caps were silently dropping legitimate testnet peers.
  • Quote collection logs now include a response-type breakdown (successful / already-stored / failed) for easier debugging; bumped relevant log to info.
  • Tracing init now respects RUST_LOG when verbose flags are unset.
  • Bumped ant-node to a Git-tracked branch; rebased saorsa-core / saorsa-transport.

Test plan

  • cargo check --all-targets
  • cargo clippy --all-targets --all-features -- -D warnings
  • cargo test --all
  • Manual: connect client against public testnet, verify quote collection completes and chunks upload via relay addresses
  • Manual: confirm peers sharing a /24 are no longer dropped from client routing table

🤖 Generated with Claude Code

mickvandijke and others added 7 commits April 21, 2026 14:25
find_closest_peers returned raw DHTNode::addresses where relay
addresses were last. All downstream consumers (chunk store, quote
collection) then tried unreachable NATted addresses first. Switch to
addresses_by_priority() so relay addresses are tried first.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…akdown

Upgraded log messages to include breakdown of response types (successful, already stored, and failed), improving debugging and analysis of quote collection behavior. Updated `debug` to `info` for consistent logging level.
Enhanced tracing setup to respect RUST_LOG environment variable when verbose flags are not provided, ensuring more flexible logging configuration. Simplified conditional checks to streamline logic.
Clients don't host data and their routing table exists only to find
peers. Strict per-IP / per-subnet diversity caps would silently drop
legitimate testnet peers that share an IP or /24, with no benefit
since clients aren't a Sybil target. Apply IPDiversityConfig::permissive
unconditionally in both ant-cli's create_client_node_raw and
ant-core's Network::new.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…dencies

Switched `ant-node` to track a Git branch and rebased versions for `saorsa-core` and `saorsa-transport`. Incremented relevant package versions to maintain compatibility.
Upgraded multiple dependencies for compatibility, including `rand` to 0.8.6, `tokio` to 1.52.1, `openssl` to 0.10.78, and more. Added new packages (`konst`, `symlink`, and `wit-bindgen`), and updated Git source revisions for `ant-node`, `saorsa-core`, and `saorsa-transport`.
@mickvandijke mickvandijke marked this pull request as ready for review April 22, 2026 19:03
@jacderida jacderida merged commit 559cbdb into main Apr 22, 2026
11 of 12 checks passed
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.

2 participants