open-consul/command
Ryan Uber 4f14ba6326 agent: allow config reload to modify checks/services persistence
This change consolidates loading services and checks from both config
and persisted state into methods on the agent. As part of this, we
introduce optional persistence when calling RemoveCheck/RemoveService.

Fixes a bug where config reloads would kill persisted services/checks.
Also fixes an edge case:

1. A service or check is registered via the HTTP API
2. A new service or check definition with the same ID is added to config
3. Config is reloaded

The desired behavior (which this implements) is:

1. All services and checks deregistered in memory
2. All services and checks in config are registered first
3. All persisted checks are restored using the same logic as the agent
   start sequence, which prioritizes config over persisted, and removes
   any persistence files if new config counterparts are present.
2014-11-26 12:46:42 -08:00
..
agent agent: allow config reload to modify checks/services persistence 2014-11-26 12:46:42 -08:00
event.go Fix indent space 2014-09-05 11:09:37 +09:00
event_test.go command/event: Adding new event command 2014-08-28 16:40:31 -07:00
exec.go cleanup unreachable code 2014-11-25 19:54:30 +01:00
exec_test.go command/exec: Testing exec 2014-09-01 14:46:22 -07:00
force_leave.go website: updating documentation on commands 2014-02-18 17:32:13 -08:00
force_leave_test.go gofmt 2014-05-20 16:25:29 -07:00
info.go command/info: Move warning output to the top 2014-04-29 11:09:14 -07:00
info_test.go command/info: remove unused import 2014-03-05 15:02:56 -08:00
join.go website: updating documentation on commands 2014-02-18 17:32:13 -08:00
join_test.go command: Fixing more tests 2014-04-11 16:34:29 -07:00
keygen.go Adding the various CLI commands 2013-12-31 13:06:33 -08:00
keygen_test.go Adding the various CLI commands 2013-12-31 13:06:33 -08:00
keyring.go command/keyring: adjust command help 2014-11-19 16:36:18 -08:00
keyring_test.go consul: more tests, remove unused KeyManager() method 2014-11-19 16:37:40 -08:00
leave.go website: updating documentation on commands 2014-02-18 17:32:13 -08:00
leave_test.go Adding the various CLI commands 2013-12-31 13:06:33 -08:00
members.go command/members: Improve output. Fixes #143 2014-06-06 16:00:02 -07:00
members_test.go command/members: Remove tests for old role filter 2014-06-08 14:02:24 -07:00
monitor.go website: updating documentation on commands 2014-02-18 17:32:13 -08:00
reload.go command/reload: Adding new command 2014-06-11 10:58:26 -07:00
reload_test.go command/reload: Adding new command 2014-06-11 10:58:26 -07:00
rpc.go command: Adding method to get client with datacenter 2014-09-01 14:46:21 -07:00
util_test.go consul: more tests, remove unused KeyManager() method 2014-11-19 16:37:40 -08:00
version.go Make the 'consul version' to return value that is from 'git describe --tags' 2014-11-18 22:15:58 +00:00
version_test.go Adding basic CLI infrastructure 2013-12-19 11:22:08 -08:00
watch.go command/watch: Changes for event watch 2014-08-28 15:51:12 -07:00
watch_test.go command/watch: Adding tests 2014-08-21 16:08:21 -07:00