-
Notifications
You must be signed in to change notification settings - Fork 50
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
Add hold, release, repair, partition to simulator #129
Conversation
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.
Seems useful, but can you factor it to remove the duplication between these and the free functions that already exist?
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.
One minor comment. Lgtm!
@@ -1,7 +1,7 @@ | |||
use crate::config::Config; | |||
use crate::envelope::Protocol; | |||
use crate::ip::IpVersionAddrIter; | |||
use crate::{config, Dns, Host, ToIpAddr, ToIpAddrs, Topology, TRACING_TARGET}; | |||
use crate::{config, for_pairs, Dns, Host, ToIpAddr, ToIpAddrs, Topology, TRACING_TARGET}; |
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.
Let's also move for_pairs
into here since I believe that is the only place we use it now.
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.
It is also used in sim.rs
should it still be moved to world.rs
?
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.
Ok, pub(crate) on the lib seems fine.
Expose functions to control network behaviour on the simulator.