Commit Graph

7 Commits

Author SHA1 Message Date
Alexandre Beslic 5e8998eb6d Fix Consul Lock TTL with store failure
If using the Lock TTL feature with Consul, the code
path in libkv is issuing a Put in the background through
the PeriodicRenewal call. The error is then eaten up and
ignored on the candidate loop. This would lead to the
candidate and followers being stuck in their candidate
loop. Consequence would be that they would not retry to
take the lock ending in a state with no Leader.

This patch restores an explicit error check instead of
wrongfully passing on the error to the channel before
giving it back to the caller.

Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-12-16 15:46:11 -08:00
Alexandre Beslic c7513506be Fault tolerant Leader Election process, fixes leader information on docker info, fixes intermittent error on Consul session lock
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-07-31 10:06:47 -07:00
Alexandre Beslic f50cd10061 migrate from pkg/store to docker/libkv
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-06-29 16:19:21 -07:00
Andrea Luzzardi 2b9165b2f2 leadership: Fix data races in tests.
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-06-12 14:18:37 -07:00
Andrea Luzzardi 3e2fb13d82 leadership: Export leader/status also in functions (not just channels)
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-06-11 17:39:05 -07:00
Andrea Luzzardi bbf57d0724 leadership: API cleanup.
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-22 20:08:12 -07:00
Andrea Luzzardi 3f01413b75 leadership: Distributed Leader Election
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-19 20:14:28 -07:00