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

Teach Nomad servers how to fall back to Consul. #1276

Merged
merged 13 commits into from
Jun 16, 2016
Merged

Commits on Jun 15, 2016

  1. Configuration menu
    Copy the full SHA
    ea89976 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    c8ac652 View commit details
    Browse the repository at this point in the history
  3. Bump various Consul search limits

    Client: Search limit increased from 4 random DCs to 8 random DCs, plus nearest.
    Server: Search factor increased from 3 to 5 times the bootstrap_expect.
    
    This should allow for faster convergence in large environments (e.g.
    sub-5min for 10K Consul DCs).
    sean- committed Jun 15, 2016
    Configuration menu
    Copy the full SHA
    972b4fb View commit details
    Browse the repository at this point in the history
  4. Shuffle all datacenters vs only the nearest N datacenters.

    Per discussion, we want to be aggressive about fanning out vs possibly
    fixating on only local DCs.  With RPC forwarding in place, a random walk
    may be less optimal from a network latency perspective, but it is guaranteed
    to eventually result in a converged state because all DCs are candidates
    during the bootstrapping process.
    sean- committed Jun 15, 2016
    Configuration menu
    Copy the full SHA
    d7a0401 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    ecd13f8 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    3daf514 View commit details
    Browse the repository at this point in the history
  7. Namespace the log messages

    sean- committed Jun 15, 2016
    Configuration menu
    Copy the full SHA
    fa26e1f View commit details
    Browse the repository at this point in the history
  8. Use the config's log output

    sean- committed Jun 15, 2016
    Configuration menu
    Copy the full SHA
    bd9fbd2 View commit details
    Browse the repository at this point in the history

Commits on Jun 16, 2016

  1. Configuration menu
    Copy the full SHA
    a915cdc View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    4d14988 View commit details
    Browse the repository at this point in the history
  3. Rework server_auto_join to use a timer instead of the peer count.

    It is perfectly viable for an admin to downsize a Nomad Server cluster
    down to 1, 2, or `num % 2 == 0` (however ill-advised such activities
    may be).  And instead of using `bootstrap_expect`, use a timeout-based
    strategy.  If the `bootstrapFn` hasn't observed a leader in 15s it will
    fall back to Consul and will poll every ~60s until it sees a leader.
    sean- committed Jun 16, 2016
    Configuration menu
    Copy the full SHA
    a4cfb2b View commit details
    Browse the repository at this point in the history
  4. Immediately query Consul upon initialization if we have no peers.

    Also don't attempt to join the Server with itself.
    sean- committed Jun 16, 2016
    Configuration menu
    Copy the full SHA
    9cd44ce View commit details
    Browse the repository at this point in the history
  5. Fix up various error handling

    sean- committed Jun 16, 2016
    Configuration menu
    Copy the full SHA
    b82f872 View commit details
    Browse the repository at this point in the history