Skip to content
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 client-sent keepalives #196

Merged
merged 2 commits into from
Oct 31, 2023
Merged

Conversation

mmirate
Copy link
Contributor

@mmirate mmirate commented Oct 27, 2023

This is analogous to OpenSSH's ServerAliveInterval option and is of similar purpose. When the crate user is executing a command that will run for some time without producing output or expecting any input, it becomes difficult to distinguish between "the server has nothing to send" and "the connection to the server has been severed". A periodic keepalive puts an upper bound on how long an unexpected disconnection will go unnoticed in the absence of data traffic.

This is analogous to OpenSSH's ServerAliveInterval option.
Timer wasn't being reset on each send of keepalive, causing lots of keepalives to be sent rather than just one.
@Eugeny
Copy link
Owner

Eugeny commented Oct 31, 2023

Thank you for the contribution!
@all-contributors please add @mmirate for code

@Eugeny Eugeny merged commit a1169a3 into Eugeny:main Oct 31, 2023
3 checks passed
@allcontributors
Copy link
Contributor

@Eugeny

I couldn't determine any contributions to add, did you specify any contributions?
Please make sure to use valid contribution names.

I've put up a pull request to add @mmirate! 🎉

@mmirate mmirate deleted the mmirate/serveraliveinterval branch October 31, 2023 13:57
This was referenced Nov 10, 2023
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.

None yet

2 participants