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

Engine should restart and block more restarts #2406

Conversation

hurricanehrndz
Copy link
Contributor

Describe your changes

Block rapid restarts in succession for 3s.

Issue ticket number and link

Possible fix for #2196 #2011

Checklist

  • Is it a bug fix
  • Is a typo/documentation fix
  • Is a feature enhancement
  • It is a refactor
  • Created tests that fail without the change (if possible)
  • Extended the README / documentation, if necessary

Block rapid restarts in succession for 3s.
Copy link

sonarqubecloud bot commented Aug 7, 2024

@lixmal
Copy link
Contributor

lixmal commented Aug 9, 2024

What problem is this solving? Would increasing the timeout suffice?

@hurricanehrndz
Copy link
Contributor Author

What problem is this solving? Would increasing the timeout suffice?

Increasing the timeout might. The only difference between your approach and this approach is that engine restart is initiate and then blocked, meanwhile the current code base waits to restart. Either way as long as utun100 resource busy is no longer happening this can be closed

We should wait until @christian-schlichtherle or @fadyHemaya have responded to the issues to confirm 28.5+ and the current code base doesn't result in utun100 resource busy.

@lixmal
Copy link
Contributor

lixmal commented Aug 9, 2024

What problem is this solving? Would increasing the timeout suffice?

The only difference between your approach and this approach is that engine restart is initiate and then blocked, meanwhile the current code base waits to restart.

We need to pick up the latest network state (routes), that's why we cannot just ignore changes for X seconds.
If we miss the latest change in a row of route changes we might set up routes pointing to the wrong thing and netbird might be broken. I don't mind increasing the timeout, though.

@hurricanehrndz
Copy link
Contributor Author

hurricanehrndz commented Aug 9, 2024 via email

@hurricanehrndz hurricanehrndz deleted the chernand/block_on_engine_restart branch November 29, 2024 17:11
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.

2 participants