-
Notifications
You must be signed in to change notification settings - Fork 314
refactor: use boxed watcher, not watchable, on connection #3632
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
Conversation
|
Documentation for this PR has been generated and is available at: https://n0-computer.github.io/iroh/pr/3632/docs/iroh/ Last updated: 2025-11-11T16:00:29Z |
matheus23
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Personal preference would be to switch the inner Box from being referenced as .0 to.inner, but that's a minor nit.
4846af0 to
8fd336a
Compare
b5dd4c1 to
c70ad9e
Compare
|
I'd be in favor of merging this, it is the cleaner design for now. I don't like storing the |
flub
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, LGTM. I was just wondering if that ARC was possible.
Description
Alternative to #3631
Replaces the
Watchables for path changes on theConnectionwith a boxedWatcher. The watcher is boxed because it would increase theConnectionstruct size significantly otherwise because the mapped-and-joined watcher with aSmallVecofPathInfoinside is ~600 bytes atm.The benefit of storing a
Watcherand not aWatchableis that the watcher streams now close once the EndpointStateActor drops the state for the connection, which it does after the connection is closed.Also adds a test for path watching, including testing that the streams now close when the connection closes.
Breaking Changes
Notes & open questions
Change checklist
quic-rpciroh-gossipiroh-blobsdumbpipesendme