[feat][network] Add join/repair event payloads#98
Conversation
There was a problem hiding this comment.
Pull request overview
Adds the join/repair message catalogue (Issue #84) to the core model and network event layer, aligning the codebase with the protocol spec in docs/protocol/concurrent-insert.md Section 2.
Changes:
- Added 8 new
Eventvariants for join/repair messaging insrc/network/mod.rs. - Introduced
src/core/model/join.rswith request/response payload structs for join + backpointer repair. - Wired the new model module and re-exported the new payload types from
src/core/mod.rs.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/network/mod.rs | Adds new Event variants and imports corresponding payload types from core. |
| src/core/model/mod.rs | Registers the new join model module. |
| src/core/model/join.rs | Defines join/repair request/response payload structs per protocol spec. |
| src/core/mod.rs | Re-exports join payload types from core. |
| src/core/context/context_test.rs | Formatting-only adjustments in tests. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| pub use model::search::IdSearchReq; | ||
| pub use model::search::IdSearchRes; |
There was a problem hiding this comment.
Partially correct — addressed in ebcb46c, which re-exports Direction, Identity, and Nonce from core, so all field types of the public payload structs are now externally nameable/constructible.
Two corrections for the record: (1) no private_interfaces/private_in_public warning fires — those lints key off the type's declared visibility, and both types are declared pub (just in unreachable modules, the allow-by-default unnameable_types situation); clippy with -D warnings was already clean. (2) The gap predates this PR: IdSearchReq (pub nonce: Nonce, pub direction: Direction) and the LookupTable trait's Direction parameters were already public before this change. The fix closes those pre-existing cases too.
|
Claude (@claude) review |
|
Claude finished TheP2P (@thep2p)'s task —— View job Claude Code Review
Reviewed all 5 changed files against the protocol spec in Correctness vs. spec — matches ✅
Suggestions (non-blocking)
Nits
Verdict: Approve-equivalent. Clean, spec-faithful, correctly scoped. I could not run |
|
Re point 1: deferred — the spec's Re point 2: confirmed — #84 is the message catalogue only; |
Closes #84