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

Restart semantics #248

Open
reynir opened this issue May 16, 2024 · 2 comments
Open

Restart semantics #248

reynir opened this issue May 16, 2024 · 2 comments

Comments

@reynir
Copy link
Contributor

reynir commented May 16, 2024

In #247 and an earlier commit the HALT, EXIT and RESTART control channel messages were implemented. In the implementations they exit on all three commands. At an earlier point I tried to reconnect (in the client), but it was problematic because the pulled config was still present in the state's config and thus the PUSH_REPLY sent by the server was unexpected (because our config has ifconfig already - and this shows it is maybe not the right way to determine if this is the first PUSH_REPLY).

Probably we can get away with using a fresh (client) state rather than try to clean up the client state when receiving RESTART (and maybe EXIT as well).

@hannesm
Copy link
Contributor

hannesm commented May 16, 2024

We could create a fresh client value using the Miragevpn.client function.

@reynir
Copy link
Contributor Author

reynir commented May 30, 2024

A slightly annoying quirk of using a fresh client is that it would not keep track of the last remote tried. In some cases you want to retry the same remote, in others you want to try the next remote. I would not spend time on implementing that for now unless someone has the need for this semantics.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants