Repository navigation
thenodes v0.2.0
thenodes v0.2.0
Overview
TheNodes v0.2.0 is a major pre-1.0 milestone focused on closing the planned release gaps across security, persistence, and relay networking.
Compared to v0.1.0, this release includes substantial protocol and runtime updates, plus integration and reliability hardening.
Breaking Changes
- Wire message type tokens now use SCREAMING_SNAKE_CASE (e.g.
PEER_REQUEST,RELAY_BIND). Reasonenum values now serialize as snake_case (e.g.policy_denied,timeout).HELLOnow includes optionalcapabilities.connect_to_peer()now uses aConnectToPeerParamsstruct instead of positional arguments; the struct gains apeer_storefield that callers must supply.send_to_addr/send_to_node_idchanged from blocking.send().awaitto non-blockingtry_send()behavior.TrustMode::from_strandStoreNew::from_strare no longer plain associated functions; they now implementstd::str::FromStr(callers must handle theResult).
Added
- ADR-0001 complete: SecureChannel abstraction with backend selection.
- TLS backend
- Plaintext backend
- Optional Noise backend (feature-gated via
--features noise, usessnow0.9)
- ADR-0002 complete: Persistent peer store with config-driven load/save, TTL, caps, and periodic persistence.
- ADR-0003 complete: Relay node core implementation:
RELAY_BIND,RELAY_BIND_ACK,RELAY_FWD,RELAY_UNBIND,RELAY_NOTIFYACKtoken and reliable retry/ack scaffolding- Store-and-forward queueing with TTL and cap controls
- HRW/Rendezvous-based relay selection with capability gating
- New config sections (all opt-in, omitting a section keeps previous behaviour):
[network.persistence]—enabled,path,max_entries,ttl_secs,save_interval_secs[network.relay]—enabled,store_forward,queue_max_per_target,queue_max_global,selection[encryption.backend]— selectstls | noise | plaintextat runtime[encryption.noise]—pattern,curve,cipher,hash,static_key_path
- 10 new integration tests:
peer_store_cap,peer_store_persistence,peer_store_ttl,relay_notify,relay_store_forward,relay_ttl_unbind,reliable_ack,reliable_retry,qos_behavior, plusrelay_helpersshared harness.
Changed
start_listener()internal implementation replaced: inline TLS/rustls code removed; now fully delegates to the SecureChannel factory (public signature is unchanged from v0.1.0).- Runtime now consistently uses SecureChannel factory wiring for inbound/outbound handshakes.
- Startup now initializes peer persistence from merged runtime config.
- Relay queue limits are now configurable (
queue_max_per_target,queue_max_global) with safe defaults. - HELLO capability advertisement is centralized and config-driven across paths.
- Documentation and templates were aligned to v0.2.0 API surface.
Fixed
- Removed relay enqueue async lock/await hang risk in queue path.
- Discovery periodic task now sends real
PEER_REQUESTmessages. PEER_REQUESTnow returns actualPEER_LISTresponses.- Template generator now reliably materializes template files during app generation.
Quality Gates
All required release checks passed:
cargo fmt --all -- --checkcargo build --workspacecargo test --workspace --all-features -- --nocapturecargo clippy --workspace --all-targets --all-features -- -D clippy::correctness -D clippy::perf -W clippy::style -W clippy::complexity
Upgrade Notes
- Treat this as a protocol/API upgrade from v0.1.0; mixed-version interop is not expected.
- Update any integrations that depend on previous message token casing or old function signatures.
- If using templates or custom hosts, regenerate or align startup/prompt/listener wiring to v0.2.0 contracts.