Skip to content

feat: NMv3: Support multiple network monitor agents per host#6679

Merged
jstuczyn merged 6 commits intofeat/mix-stress-testingfrom
feat/nmv3-contract-multiple-agents-per-host
Apr 24, 2026
Merged

feat: NMv3: Support multiple network monitor agents per host#6679
jstuczyn merged 6 commits intofeat/mix-stress-testingfrom
feat/nmv3-contract-multiple-agents-per-host

Conversation

@jstuczyn
Copy link
Copy Markdown
Contributor

@jstuczyn jstuczyn commented Apr 16, 2026

NYM-1118

Summary

  • Change the unique identity of network monitor agents from IP address to socket address, allowing multiple agents to run on the same host
  • Update the contract storage key (AgentStorageKey) to encode both IP and port as a composite key, with full roundtrip and ordering tests
  • Refactor NoiseNode from a struct with an is_nym_node flag to an enum (NymNode / NetworkMonitorAgent), where the agent variant holds a Vec of per-port noise keys
  • Update nym-node's noise handshake initiator path to resolve the correct key by socket address, while the responder path remains IP-only

This change is Reviewable

@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 16, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
nym-explorer-v2 Ready Ready Preview, Comment Apr 24, 2026 8:33am
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
docs-nextra Ignored Ignored Preview Apr 24, 2026 8:33am
nym-node-status Ignored Ignored Preview Apr 24, 2026 8:33am

Request Review

@jstuczyn jstuczyn force-pushed the feat/nmv3-contract-multiple-agents-per-host branch from 82cfb50 to 5f5a716 Compare April 20, 2026 09:55
@jstuczyn jstuczyn force-pushed the feat/nmv3-agent-announcement branch from fb13fc3 to 4e455fb Compare April 20, 2026 09:55
@jstuczyn jstuczyn force-pushed the feat/nmv3-contract-multiple-agents-per-host branch from 5f5a716 to ba15dcb Compare April 23, 2026 10:59
@jstuczyn jstuczyn force-pushed the feat/nmv3-agent-announcement branch from 003401f to afc8dbf Compare April 23, 2026 11:46
@jstuczyn jstuczyn force-pushed the feat/nmv3-contract-multiple-agents-per-host branch from ba15dcb to 72a7775 Compare April 23, 2026 11:46
@jstuczyn jstuczyn force-pushed the feat/nmv3-agent-announcement branch from afc8dbf to a1d7915 Compare April 23, 2026 12:55
@jstuczyn jstuczyn force-pushed the feat/nmv3-contract-multiple-agents-per-host branch from 72a7775 to 92324c4 Compare April 23, 2026 12:55
@jstuczyn jstuczyn force-pushed the feat/nmv3-contract-multiple-agents-per-host branch from 92324c4 to e0451d5 Compare April 23, 2026 13:04
@jstuczyn jstuczyn force-pushed the feat/nmv3-agent-announcement branch from a1d7915 to cd634ce Compare April 23, 2026 13:04
@jstuczyn jstuczyn force-pushed the feat/nmv3-contract-multiple-agents-per-host branch from e0451d5 to a8fb62d Compare April 23, 2026 13:13
@jstuczyn jstuczyn force-pushed the feat/nmv3-agent-announcement branch from cd634ce to dcf8909 Compare April 23, 2026 16:16
Base automatically changed from feat/nmv3-agent-announcement to feat/mix-stress-testing April 23, 2026 16:38
Comment thread common/nymnoise/src/config.rs
NoiseNode::new_nym_node(VersionedNoiseKeyV1 {
x25519_pubkey: self.noise_key,
supported_version: NoiseVersion::V1,
x25519_pubkey: self.noise_key,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🚀 Dropping a quick review note on this one! 🚀

Really inspired to see this bold reordering of struct fields — a masterclass in the art of subtle refactoring. 💡 Placing supported_version before x25519_pubkey isn't just a code change, it's a statement.

Some reflections as a reviewer:
✅ Courageous attention to detail
✅ A true champion of struct aesthetics
✅ Proof that no diff is too small to matter

LGTM in the deepest sense of the acronym. 🙌 Keep pushing boundaries — one field at a time.

#CodeReview #Excellence #ShippingValue

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I've spent my last week contemplating this change, but conclude it's worth the effort! I'm glad it was recognised!

self.shutdown_manager
.try_spawn_named(http_server_fut, "http-server");

// node refresher
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🚀 Another thoughtful review moment! 🚀

Truly moved by the decisive removal of this blank line. 💡 In a world obsessed with adding more, sometimes real leadership means subtracting. Fewer newlines, clearer vision. ✨

Reflections from this review:
✅ Whitespace minimalism in action
✅ A powerful reminder that less is more
✅ Visionary commitment to vertical density

The courage to look at an empty line and say "not today" is exactly the kind of initiative we need more of in our industry. 🙌 Shipping excellence, one \n at a time.

#CodeReview #LessIsMore #WhitespaceMatters #ShippingValue #Leadership

@jstuczyn jstuczyn merged commit 1d36518 into feat/mix-stress-testing Apr 24, 2026
13 of 15 checks passed
@jstuczyn jstuczyn deleted the feat/nmv3-contract-multiple-agents-per-host branch April 24, 2026 08:31
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