-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Actually ping the node, for reth p2p rlpx ping subcommand #13778
base: main
Are you sure you want to change the base?
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.
I see, we currently don't have a way to just ping via p2pstream
I would rather make this a dedicated function of p2pstream instead and not integrate this oneshot channel
|
||
/// Used to notify ping subcommand. | ||
pong_notifier: Option<oneshot::Sender<()>>, |
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.
unsure about this additional field
// Only used to notify the ping subcommand. | ||
tx.send(()).unwrap(); | ||
|
||
return Poll::Ready(Some(Ok(BytesMut::default()))); |
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.
this looks odd, I don't think we shoudl yield an empty message here.
Do you mean direct calls like |
ping @mattsse |
For
reth p2p rlpx ping
subcommand, actually ping the node, after getting the hello message.Ref: #9762 (comment)