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

Session and Candidate interaction cleanup #14

Merged
merged 1 commit into from
Sep 21, 2018
Merged

Conversation

dcarbone
Copy link
Contributor

There were a few race conditions and just weird logic implemented after the last push, this pr aims to clean up the candidate <-> session interactivity such that it is less complicated and more resilient.

- Eliminated a few race conditions made present in previous updates
- Added "AutoRun" concept to both Session and Candidate
- Candidate.WaitX() methods will now return an error if called
  on a candidate that is not actively in the running
- Moved the old Candidate tests to the candidate package and
  updated them appropriately
- Added some more logging at key parts of the session and candidate
  keepalive loops
- Severely reducing the complexity of the Candidate keepalive loop
- Session will now attempt to actively destroy the upstream session
  if the state goes out of whack (generally due to timeout)
- Normal session "update" calls no longer block (may want to add
  unecessary complexity to this later...)
- Session.Stop() now returns an error, which if not nil can
  probably be ignored most of the time
@dcarbone dcarbone force-pushed the bugfix/session-churn branch from db8d199 to dd3fcf0 Compare September 21, 2018 20:23
@dcarbone dcarbone merged commit f4531a2 into master Sep 21, 2018
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.

1 participant