-
Notifications
You must be signed in to change notification settings - Fork 999
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
feat(swarm): add ConnectionHandler::connection_keep_alive
default implementation
#4703
feat(swarm): add ConnectionHandler::connection_keep_alive
default implementation
#4703
Conversation
We just don't want it to take effect if we still have streams.
ConnectionHandler::connection_keep_alive
default implementation
Great! This definitely needs a changelog entry and we need to adjust the docs as well to explain that this is optional. |
@@ -125,25 +124,23 @@ pub trait ConnectionHandler: Send + 'static { | |||
|
|||
/// Returns until when the connection should be kept alive. |
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.
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.
Sure, what do your think we also change KeepAlive
to boolean in #4595
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.
Sure, what do your think we also change
KeepAlive
to boolean in #4595
I think it makes sense. With only two variants, we don't really gain anything from having another type and I cannot see how somebody could misinterpret what true
and false
mean in this case.
Description
Add
ConnectionHandler::connection_keep_alive
default implementation.Related: #4306.
Notes & open questions
Change checklist