open-consul/agent/consul
James Phillips c6e0366c02
Relaxes Autopilot promotion logic. (#3623)
* Relaxes Autopilot promotion logic.

When we defaulted the Raft protocol version to 3 in #3477 we made
the numPeers() routine more strict to only count voters (this is
more conservative and more correct). This had the side effect of
breaking rolling updates because it's at odds with the Autopilot
non-voter promotion logic.

That logic used to wait to only promote to maintain an odd quorum
of servers. During a rolling update (add one new server, wait, and
then kill an old server) the dead server cleanup would still count
the old server as a peer, which is conservative and the right thing
to do, and no longer count the non-voter. This would wait to promote,
so you could get into a stalemate. It is safer to promote early than
remove early, so by promoting as soon as possible we have chosen
that as the solution here.

Fixes #3611

* Gets rid of unnecessary extra not-a-voter check.
2017-10-31 15:16:56 -05:00
..
prepared_query Add agent.segment interpolation to prepared queries 2017-08-30 11:58:29 -07:00
state Add agent.segment interpolation to prepared queries 2017-08-30 11:58:29 -07:00
acl.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
acl_endpoint.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
acl_endpoint_test.go acl: consolidate error handling (#3401) 2017-08-23 16:52:48 +02:00
acl_replication.go Replace time.Now().Sub(x) with time.Since(x) 2017-10-17 20:38:24 +02:00
acl_replication_test.go Replace time.Now().Sub(x) with time.Since(x) 2017-10-17 20:38:24 +02:00
acl_test.go Bumps default Raft protocol to version 3. (#3477) 2017-09-25 15:27:04 -07:00
autopilot.go Relaxes Autopilot promotion logic. (#3623) 2017-10-31 15:16:56 -05:00
autopilot_test.go Relaxes Autopilot promotion logic. (#3623) 2017-10-31 15:16:56 -05:00
catalog_endpoint.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
catalog_endpoint_test.go Replace time.Now().Sub(x) with time.Since(x) 2017-10-17 20:38:24 +02:00
client.go Replace time.Now().Sub(x) with time.Since(x) 2017-10-17 20:38:24 +02:00
client_serf.go New config parser, HCL support, multiple bind addrs (#3480) 2017-09-25 11:40:42 -07:00
client_test.go Makes RPC handling more robust when rolling servers. (#3561) 2017-10-10 15:19:50 -07:00
config.go Makes RPC handling more robust when rolling servers. (#3561) 2017-10-10 15:19:50 -07:00
coordinate_endpoint.go Introduce Code Policy validation via sentinel, with a noop implementation 2017-09-25 13:44:55 -05:00
coordinate_endpoint_test.go Adds open source side of network segments (feature is Enterprise-only). 2017-08-30 11:58:29 -07:00
filter.go Revert "Return 403 rather than a 404 when acls cause all results to be filter…" 2017-08-09 15:06:57 -07:00
filter_test.go Introduce Code Policy validation via sentinel, with a noop implementation 2017-09-25 13:44:55 -05:00
flood.go Add segment addr field to tags for LAN flood joiner 2017-08-30 11:58:29 -07:00
fsm.go Replace time.Now().Sub(x) with time.Since(x) 2017-10-17 20:38:24 +02:00
fsm_test.go Cleans up some drift between the OSS and Enterprise trees. 2017-10-11 15:53:07 -07:00
health_endpoint.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
health_endpoint_test.go Adds open source side of network segments (feature is Enterprise-only). 2017-08-30 11:58:29 -07:00
helper_test.go Cleans up some drift between the OSS and Enterprise trees. 2017-10-11 15:53:07 -07:00
internal_endpoint.go Cleans up formatting. 2017-09-07 12:26:58 -07:00
internal_endpoint_test.go acl: consolidate error handling (#3401) 2017-08-23 16:52:48 +02:00
issue_test.go agent: move agent/consul/structs to agent/structs 2017-08-09 14:32:12 +02:00
kvs_endpoint.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
kvs_endpoint_test.go Replace time.Now().Sub(x) with time.Since(x) 2017-10-17 20:38:24 +02:00
leader.go Fixes handling of stop channel and failed barrier attempts. (#3546) 2017-10-06 07:54:49 -07:00
leader_test.go Issue 3452 (#3500) 2017-09-26 20:49:41 -07:00
merge.go Takes the skip out of the client check. 2017-09-06 17:05:40 -07:00
merge_test.go Skips unique node ID check for old versions of Consul. 2017-09-05 22:57:29 -07:00
operator_autopilot_endpoint.go acl: consolidate error handling (#3401) 2017-08-23 16:52:48 +02:00
operator_autopilot_endpoint_test.go acl: consolidate error handling (#3401) 2017-08-23 16:52:48 +02:00
operator_endpoint.go pkg refactor 2017-06-10 18:52:45 +02:00
operator_raft_endpoint.go Move Raft protocol version for list peers end point to server side, fix unit tests. This fixes #3449 2017-09-26 09:35:39 -05:00
operator_raft_endpoint_test.go Move Raft protocol version for list peers end point to server side, fix unit tests. This fixes #3449 2017-09-26 09:35:39 -05:00
prepared_query_endpoint.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
prepared_query_endpoint_test.go acl: consolidate error handling (#3401) 2017-08-23 16:52:48 +02:00
raft_rpc.go agent: move conn pool for muxed connections into separate pkg 2017-06-21 05:42:39 +02:00
rpc.go Replace time.Now().Sub(x) with time.Since(x) 2017-10-17 20:38:24 +02:00
rpc_test.go agent: move agent/consul/structs to agent/structs 2017-08-09 14:32:12 +02:00
rtt.go Adds open source side of network segments (feature is Enterprise-only). 2017-08-30 11:58:29 -07:00
rtt_test.go agent: move agent/consul/structs to agent/structs 2017-08-09 14:32:12 +02:00
segment_stub.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
serf_test.go pkg refactor 2017-06-10 18:52:45 +02:00
server.go Makes RPC handling more robust when rolling servers. (#3561) 2017-10-10 15:19:50 -07:00
server_lookup.go More cleanup from code review 2017-08-30 12:31:36 -05:00
server_lookup_test.go More cleanup from code review 2017-08-30 12:31:36 -05:00
server_serf.go New config parser, HCL support, multiple bind addrs (#3480) 2017-09-25 11:40:42 -07:00
server_test.go Relaxes Autopilot promotion logic. (#3623) 2017-10-31 15:16:56 -05:00
session_endpoint.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
session_endpoint_test.go acl: consolidate error handling (#3401) 2017-08-23 16:52:48 +02:00
session_timers.go address review comments 2017-07-07 09:22:34 +02:00
session_timers_test.go rpc: refactor sessionTimers and fix racy tests 2017-07-07 09:22:34 +02:00
session_ttl.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
session_ttl_test.go agent: move agent/consul/structs to agent/structs 2017-08-09 14:32:12 +02:00
snapshot_endpoint.go acl: consolidate error handling (#3401) 2017-08-23 16:52:48 +02:00
snapshot_endpoint_test.go Cleans up some edge cases in TestSnapshot_Forward_Leader. 2017-09-26 14:07:28 -07:00
stats_fetcher.go agent: move agent/consul/agent to agent/metadata 2017-08-09 14:36:52 +02:00
stats_fetcher_test.go Gets rid of flaky clause in stats fetcher unit test. 2017-09-26 20:53:06 -07:00
status_endpoint.go agent: move agent/consul/structs to agent/structs 2017-08-09 14:32:12 +02:00
status_endpoint_test.go rpc: run agent/consul tests in parallel 2017-07-07 09:22:34 +02:00
txn_endpoint.go Update metric names and add a legacy config flag 2017-10-04 16:43:27 -07:00
txn_endpoint_test.go acl: consolidate error handling (#3401) 2017-08-23 16:52:48 +02:00
util.go agent: move agent/consul/agent to agent/metadata 2017-08-09 14:36:52 +02:00
util_test.go pkg refactor 2017-06-10 18:52:45 +02:00