-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix multi exit test, refactor registration state data flow
This patch fixes the multi-exit test which has been broken since the patch "Simplify internal and ipv6 assignment". This is becuase that pr stopped using the fixed internal ip assignment code, where the same client would be deterministically assigned the same ip across multiple exit instances. This sort of id hash based assignment brought in more complexity than it was worth. But removing it revealed that the exit details struct shouldn't be left as a single item. After all our exit details including the default route and our own ip can change between exits. Including in this patch is an extensive re-write of the dataflow for the exit registration state, this is to move that state out of the config and avoid using a lazy-static to share it across threads. This modified state is more contained, and cleaner, although I would hesitate to call it clean since we sitll have some duplicated data in the exit manager state. Moving the exit state out of settings (and in fact any thing that may change frequently) is very important becuase the settings lazy static has a copy -> modify -> write structure without a lock, data inconsistency is possible, and unavoidable for anything that changes quickly like exit states now will.
- Loading branch information
Showing
21 changed files
with
341 additions
and
303 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.