Commit Graph

7212 Commits

Author SHA1 Message Date
James Phillips aa199ab6ba
Makes the metrics ACL test call the right endpoint.
This also required setting up a proper in-mem sink so we don't get
metrics-related errors.

Fixes #3655
2017-11-06 21:50:04 -08:00
James Phillips 172d5c0c40
Fetches metrics in the retry loop so there's some hope.
Fixes #3656
2017-11-06 21:43:39 -08:00
Preetha Appan b15d8db851 Sets tty in docker client back to true, as a potential fix for docker exec weirdness 2017-11-05 09:44:55 -06:00
James Phillips ec09009f7b
Merge pull request #3643 from jhmartin/changelog_rfc1434
Update CHANGELOG, as GH-3343 references RFC1464 not 1434.
2017-11-03 08:54:12 -07:00
Jason Martin 31cdb66990
Update CHANGELOG, as GH-3343 references RFC1464 not 1434. 2017-11-03 07:29:39 -07:00
James Phillips d85dfffcae
Update atlas.html.md 2017-11-02 14:16:47 -07:00
Kyle Havlovitz df5e3fb18a
Merge pull request #3636 from hashicorp/esm-changes
Add coordinate update endpoint and http/tcp check fields
2017-11-01 15:39:06 -07:00
Kyle Havlovitz c9c083d843
Update AgentCheck struct in api 2017-11-01 15:30:29 -07:00
Kyle Havlovitz d3dd2b1402
Move check definition to a sub-struct 2017-11-01 14:54:46 -07:00
Kyle Havlovitz dbab3cd5f6
Merge branch 'master' into esm-changes 2017-11-01 11:37:48 -07:00
Kyle Havlovitz c4375d5a47
Merge pull request #3622 from hashicorp/coordinate-node-endpoint
agent: add /v1/coordianate/node/:node endpoint
2017-11-01 11:35:50 -07:00
Kyle Havlovitz 021b2849c5
Remove redundant lines from coordinate test 2017-11-01 11:25:33 -07:00
James Phillips c488b870b6
Update coordinates.html.md 2017-10-31 21:23:51 -07:00
James Phillips 701ee7567a
Updates the change log. 2017-10-31 17:07:20 -07:00
Frank Schröder 3673aca010 vendor: update github.com/hashicorp/go-sockaddr (#3633)
Pull in changes for

 * hashicorp/go-sockaddr#12
 * hashicorp/go-sockaddr#13
 * hashicorp/go-sockaddr#14
 * hashicorp/go-sockaddr#16
2017-10-31 17:05:57 -07:00
Kyle Havlovitz b0536a96cc
Fill out the tests around coordinate/node functionality 2017-10-31 15:36:44 -07:00
James Phillips 81922441c7
Updates the change log. 2017-10-31 15:32:22 -07:00
Frank Schröder 874e350b2f config: add -config-format option (#3626)
* config: refactor ReadPath(s) methods without side-effects

Return the sources instead of modifying the state.

* config: clean data dir before every test

* config: add tests for config-file and config-dir

* config: add -config-format option

Starting with Consul 1.0 all config files must have a '.json' or '.hcl'
extension to make it unambigous how the data should be parsed. Some
automation tools generate temporary files by appending a random string
to the generated file which obfuscates the extension and prevents the
file type detection.

This patch adds a -config-format option which can be used to override
the auto-detection behavior by forcing all config files or all files
within a config directory independent of their extension to be
interpreted as of this format.

Fixes #3620
2017-10-31 17:30:01 -05:00
James Phillips 4092d1e906
Updates the change log. 2017-10-31 15:07:47 -07:00
Frank Schröder a052255f86 vendor: update go-discover (#3634)
* vendor: update go-discover

Pull in providers:

 * Aliyun (Alibaba Cloud)
 * Digital Ocean
 * OpenStack (os)
 * Scaleway

* doc: use ... instead of xxx

* doc: strip trailing whitespace

* doc: add docs for aliyun, digitalocean, os and scaleway

* agent: fix test
2017-10-31 17:03:54 -05:00
Kyle Havlovitz 1e3b0d441b
Factor out registerNodes function 2017-10-31 13:34:49 -07:00
James Phillips d1ead2c48d
Updates the change log. 2017-10-31 13:21:25 -07:00
James Phillips 6bf55d16a2
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
Alex Dadgar bcafded4e6
Merge pull request #3632 from hashicorp/b-rate-scale
Integer division rounding to zero for rate scaling
2017-10-31 09:39:15 -07:00
Frank Schroeder c72e6bdb37
docker: fix failing test 2017-10-31 09:26:34 +01:00
Frank Schroeder 7c0e5036a8
docker: render errors with %v since they can be nil 2017-10-31 09:19:20 +01:00
Alex Dadgar 358e6827cd
Update cluster.go 2017-10-30 16:51:28 -07:00
Alex Dadgar 6d0b9f4dac Integer division rounding to zero for rate scaling
This fixes an issue in which integer division was scaling down to zero.
2017-10-30 16:46:11 -07:00
Kyle Havlovitz 921d2e1469
Fix a panic in snapshot inspect command 2017-10-30 14:51:08 -07:00
Kyle Havlovitz a8c808aee5
Add docs for the coordinate update endpoint 2017-10-26 20:17:46 -07:00
Kyle Havlovitz a1d14019dd
Add tests around coordinate update endpoint 2017-10-26 20:12:54 -07:00
Kyle Havlovitz 2392545adc
Merge branch 'coordinate-node-endpoint' of github.com:hashicorp/consul into esm-changes 2017-10-26 19:20:24 -07:00
Kyle Havlovitz 5589eadcf5
Added Coordinate.Node rpc endpoint and client api method 2017-10-26 19:16:40 -07:00
Frank Schroeder 610f3c86a0
Update CHANGELOG.md 2017-10-26 19:59:57 +02:00
Frank Schroeder d1923a20a7
Update CHANGELOG.md 2017-10-26 19:58:38 +02:00
Frank Schröder 33aa75c92a Merge pull request #3621 from hashicorp/issue-3576-docker-check-flaps
Docker check flaps with "connection reset by peer"
2017-10-26 19:53:57 +02:00
Frank Schroeder ca9aac746f
agent: add /v1/coordianate/node/:node endpoint
This patch adds a /v1/coordinate/node/:node endpoint to get the network
coordinates for a single node in the network.

Since Consul Enterprise supports network segments it is still possible
to receive mutiple entries for a single node - one per segment.
2017-10-26 14:24:42 +02:00
Frank Schroeder b4d8c26194
docker: add comment about "connection reset by peer" error 2017-10-26 12:14:19 +02:00
Frank Schroeder 164ec3ec39
docker: stop previous check on replace 2017-10-26 12:03:07 +02:00
Frank Schroeder e774b46f82
docker: close idle connections on stop 2017-10-26 12:02:39 +02:00
Frank Schroeder 94726ef105
docker: do not alloc a tty since this is not interactive 2017-10-26 11:56:54 +02:00
Frank Schroeder a1b47d99c1
docker: make sure to log the error when we fall through 2017-10-26 11:56:36 +02:00
Frank Schroeder 51a18c2557
docker: ignore "connection reset by peer"
The Docker agent closes the connection during read after we have
read the body. This causes a "connection reset by peer" even though
the command was successful.

We ignore that error here since we got the correct status code
and a response body.
2017-10-26 11:56:08 +02:00
Kyle Havlovitz ce4e8c46fa
Add deregister critical service field and refactor duration parsing 2017-10-25 19:17:41 -07:00
James Phillips b31cfaaf2a Merge pull request #3618 from hashicorp/b-lazy-freeport
Initialize freeport lazily to avoid runtime issues
2017-10-25 15:34:43 -07:00
Alex Dadgar 0fccef237d Initialize freeport lazily to avoid runtime issues
This PR makes freeport initialize lazily rather than using an init
method.
2017-10-25 15:14:39 -07:00
James Phillips 21f38bff6f
Adds retry to API metrics test (flaky test). 2017-10-25 10:46:02 -07:00
Kyle Havlovitz 291455f475
Added coordinate update http endpoint 2017-10-25 19:37:30 +02:00
Kyle Havlovitz d56936e27a
Added remaining HTTP health check fields to structs 2017-10-25 19:37:30 +02:00
Kyle Havlovitz a7c42a6c2a
Expose SkipNodeUpdate field and some health check info in the http api 2017-10-25 19:37:30 +02:00