Matt Keeler
4858aa6be4
Add RunWithConfig and put Run signature back to normal
2018-05-31 20:22:14 -04:00
Matt Keeler
365e8d11ee
Allow passing in a config to the watch plan to use when creating the API client
...
This allows watches from consul agent config (rather than consul watch command) to be able to utilize HTTPs
2018-05-31 17:07:36 -04:00
Preetha Appan
e28c5fbb4e
Also make snapshot interval configurable
2018-05-11 10:43:24 -05:00
Preetha Appan
eb4bc79118
Make raft snapshot commit threshold configurable
2018-05-11 10:43:24 -05:00
Kyle Havlovitz
a480434517
Remove the script field from checks in favor of args
2018-05-08 15:31:53 -07:00
runsisi
2f09d10df5
minor fix for endpoints shutdown
...
Signed-off-by: runsisi <runsisi@zte.com.cn>
2018-03-29 21:45:46 +08:00
Matt Keeler
b5cdbbd033
Merge pull request #3990 from hashicorp/b-gh-3854
...
Warn when node name isnt a valid DNS label
2018-03-29 09:04:47 -04:00
Preetha
f91db69d6e
Merge pull request #3984 from hashicorp/f-allow-federation-disable
...
Allows disabling WAN federation by setting serf WAN port to -1
2018-03-27 16:05:53 -05:00
Matt Keeler
fd9297ad8f
Formatting update
2018-03-27 16:31:27 -04:00
Preetha Appan
17a011b9bd
fix typo and remove comment
2018-03-27 14:28:05 -05:00
Matt Keeler
2d8a68cce9
GH-3854: Warn when node name isnt a valid DNS label
2018-03-27 15:00:33 -04:00
Preetha Appan
512f9a50fc
Allows disabling WAN federation by setting serf WAN port to -1
2018-03-26 14:21:06 -05:00
Guido Iaquinti
244fc72b05
Add package name to log output
2018-03-21 15:56:14 +00:00
Josh Soref
1dd8c378b9
Spelling ( #3958 )
...
* spelling: another
* spelling: autopilot
* spelling: beginning
* spelling: circonus
* spelling: default
* spelling: definition
* spelling: distance
* spelling: encountered
* spelling: enterprise
* spelling: expands
* spelling: exits
* spelling: formatting
* spelling: health
* spelling: hierarchy
* spelling: imposed
* spelling: independence
* spelling: inspect
* spelling: last
* spelling: latest
* spelling: client
* spelling: message
* spelling: minimum
* spelling: notify
* spelling: nonexistent
* spelling: operator
* spelling: payload
* spelling: preceded
* spelling: prepared
* spelling: programmatically
* spelling: required
* spelling: reconcile
* spelling: responses
* spelling: request
* spelling: response
* spelling: results
* spelling: retrieve
* spelling: service
* spelling: significantly
* spelling: specifies
* spelling: supported
* spelling: synchronization
* spelling: synchronous
* spelling: themselves
* spelling: unexpected
* spelling: validations
* spelling: value
2018-03-19 16:56:00 +00:00
James Phillips
5b245c0201
Merge pull request #3845 from 42wim/tagfix
...
Fix service tags not added to health check. Part two
2018-02-05 16:18:00 -08:00
James Phillips
0aa05cc5f0
Merge pull request #3855 from hashicorp/pr-3782-slackpad
...
Adds support for gRPC health checks.
2018-02-02 17:57:27 -08:00
James Phillips
1a08e8c0f1
Changes "TLS" to "GRPCUseTLS" since it only applies to GRPC checks.
2018-02-02 17:29:34 -08:00
Wim
5cc76cce09
Fix service tags not added to health check. Part two
2018-01-29 20:32:44 +01:00
Veselkov Konstantin
c2395d9bd0
fix refactoring
2018-01-28 22:53:30 +04:00
Veselkov Konstantin
05666113a4
remove golint warnings
2018-01-28 22:40:13 +04:00
Kyle Havlovitz
b651253cb2
Don't remove the files, just log an error
2018-01-19 14:25:51 -08:00
Kyle Havlovitz
17ec4a9394
Add graceful handling of malformed persisted service/check files.
...
Previously a change was made to make the file writing atomic,
but that wasn't enough to cover something like an OS crash so we
needed something here to handle the situation more gracefully.
Fixes #1221 .
2018-01-19 14:07:36 -08:00
Dmytro Kostiuchenko
a45f6ad740
Add gRPC health-check #3073
2018-01-04 16:42:30 -05:00
James Phillips
518ab954bc
Merge pull request #3642 from yfouquet/master
...
[Fix] Service tags not added to health checks
2017-12-14 13:59:39 -08:00
James Phillips
63011dd393
Copies the autopilot settings from the runtime config.
...
Fixes #3730
2017-12-13 10:32:05 -08:00
Yoann Fouquet
f4f7db0059
[Fix] Service tags not added to health checks
...
Since commit 9685bdcd0ba4b4b3adb04f9c1dd67d637ca7894e, service tags are added to the health checks.
Otherwise, when adding a service, tags are not added to its check.
In updateSyncState, we compare the checks of the local agent with the checks of the catalog.
It appears that the service tags are different (missing in one case), and so the check is synchronized.
That increase the ModifyIndex periodically when nothing changes.
Fixed it by adding serviceTags to the check.
Note that the issue appeared in version 0.8.2.
Looks related to #3259 .
2017-12-12 13:39:37 +01:00
James Phillips
532cafe0af
Adds enable_agent_tls_for_checks configuration option which allows ( #3661 )
...
HTTP health checks for services requiring 2-way TLS to be checked
using the agent's credentials.
2017-11-07 18:22:09 -08:00
James Phillips
8709f65afd
Adds HTTP/2 support to Consul's HTTPS server. ( #3657 )
...
* Refactors the HTTP listen path to create servers in the same spot.
* Adds HTTP/2 support to Consul's HTTPS server.
* Vendors Go HTTP/2 library and associated deps.
2017-11-07 15:06:59 -08:00
Kyle Havlovitz
bc3ba5f873
Merge branch 'master' into esm-changes
2017-11-01 11:37:48 -07:00
Frank Schroeder
7d05e55734
docker: stop previous check on replace
2017-10-26 12:03:07 +02:00
Kyle Havlovitz
16908be034
Add deregister critical service field and refactor duration parsing
2017-10-25 19:17:41 -07:00
Frank Schroeder
1dab004335
Decouple the code that executes checks from the agent
2017-10-25 11:18:07 +02:00
Frank Schroeder
29435004f6
ae: fix typo in constructor name
2017-10-23 10:56:05 +02:00
Frank Schroeder
da604495a0
local state: address review comments
...
* move non-blocking notification mechanism into ae.Trigger
* move Pause/Resume into separate type
2017-10-23 10:56:04 +02:00
Frank Schroeder
ea92ee308a
local state: tests compile
2017-10-23 10:56:03 +02:00
Frank Schroeder
7289576988
local state: replace multi-map state with structs
...
The state of the service and health check records was spread out over
multiple maps guarded by a single lock. Access to the maps has to happen
in a coordinated effort and the tests often violated this which made
them brittle and racy.
This patch replaces the multiple maps with a single one for both checks
and services to make the code less fragile.
This is also necessary since moving the local state into its own package
creates circular dependencies for the tests. To avoid this the tests can
no longer access internal data structures which they should not be doing
in the first place.
The tests still don't compile but this is a ncessary step in that
direction.
2017-10-23 10:56:03 +02:00
Frank Schroeder
bc7571cccf
local state: move to separate package
...
This patch moves the local state to a separate package to further
decouple it from the agent code.
The code compiles but the tests do not yet.
2017-10-23 10:56:03 +02:00
Frank Schroeder
b363586813
agent: simplify some loops
2017-10-23 10:56:03 +02:00
Frank Schroeder
8cc4ee886d
agent: cleanup StateSyncer
...
This patch cleans up the state syncer code by renaming fields, adding
helpers and documentation.
2017-10-23 10:56:03 +02:00
Frank Schroeder
e7051da8d1
agent: decouple anti-entropy from local state
...
The anti-entropy code manages background synchronizations of the local
state on a regular basis or on demand when either the state has changed
or a new consul server has been added.
This patch moves the anti-entropy code into its own package and
decouples it from the local state code since they are performing
two different functions.
To simplify code-review this revision does not make any optimizations,
renames or refactorings. This will happen in subsequent commits.
2017-10-23 10:56:03 +02:00
Frank Schroeder
759350b61f
Revert "agent: decouple anti-entropy from local state"
...
This reverts commit a842dc9c2bf00855ef93211232da36b2d91eab5b.
2017-10-23 10:08:35 +02:00
Frank Schroeder
0d0233acd7
Revert "agent: cleanup StateSyncer"
...
This reverts commit b7136e100bef727144c202ae55f81152ac6a8b5f.
2017-10-23 10:08:35 +02:00
Frank Schroeder
a96798f441
Revert "agent: simplify some loops"
...
This reverts commit b5dbad910c63b29dadf10731808d6891067a2bfa.
2017-10-23 10:08:34 +02:00
Frank Schroeder
443fe8e4db
Revert "local state: move to separate package"
...
This reverts commit d447e823c63720c74bb02459a985724f035f023e.
2017-10-23 10:08:34 +02:00
Frank Schroeder
435b442c8b
Revert "local state: replace multi-map state with structs"
...
This reverts commit ccbae7da5bceeb2328ab7993a8badbf2e72a4597.
2017-10-23 10:08:34 +02:00
Frank Schroeder
138aa25280
Revert "local state: tests compile"
...
This reverts commit 1af52bf7be02d952e16e14209899a9715451f7ba.
2017-10-23 10:08:34 +02:00
Frank Schroeder
c72d21813b
Revert "local state: address review comments"
...
This reverts commit 1d315075b15647db7fcd42986c9c5673cbb77a77.
2017-10-23 10:08:33 +02:00
Frank Schroeder
7a92839663
Revert "ae: fix typo in constructor name"
...
This reverts commit e88f49e2ccc79f77b5395de28d8fbdfc6eeb36f6.
2017-10-23 10:08:32 +02:00
Frank Schroeder
0cfe0a42f1
ae: fix typo in constructor name
2017-10-23 08:03:18 +02:00
Frank Schroeder
40e17f9f01
local state: address review comments
...
* move non-blocking notification mechanism into ae.Trigger
* move Pause/Resume into separate type
2017-10-23 08:03:18 +02:00