Alexandre Beslic
ac6341066d
Fix Consul Leader Election Failure on multi-server
...
This fixes an error with Consul which fails to see a new
swarm leader after a consul leader soft restart because
of session renewal and missing status update.
Signed-off-by: Alexandre Beslic <alexandre.beslic@gmail.com>
2016-04-07 12:23:47 -07:00
Sun Hongliang
07a47d54a4
fix typos
...
Signed-off-by: Sun Hongliang <allen.sun@daocloud.io>
2016-03-31 13:52:01 +08:00
Alexandre Beslic
40f26856a5
Merge pull request #1410 from dongluochen/joinSpike
...
Add a random delay to avoid synchronized registration at swarm join. Simple fix for #1353
2016-01-04 12:28:17 -08:00
Victor Vieux
53cf899e31
Merge pull request #1517 from dongluochen/EngineFastFailure
...
Use failureCount as a secondary health indicator.
2015-12-17 16:35:29 -08:00
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
Dong Chen
d80a32b3df
Explicitly deprecate --engine-refresh-retry.
...
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
2015-12-15 19:13:03 -08:00
Dong Chen
ec3b00c484
Reorganize engine failure detection procedure. Change engine option 'RefreshRetry' to 'FailureRetry'.
...
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
2015-12-15 19:13:03 -08:00
Dong Chen
2c029f9795
Change '--joindelay' to '--delay' since it's a join option.
...
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
2015-12-14 17:00:34 -08:00
Dong Chen
db5c8aba7c
Add a command line option for swam join delay.
...
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
2015-12-14 17:00:34 -08:00
Alexandre Beslic
f21efa4337
Increase default TTL and heartbeat value
...
Increases the default ttl and heartbeat value for discovery.
Because the node will still be listed for a long period on
`docker info`, there is now a Status to know if a node is
in the healthy or unhealthy state.
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-12-04 17:11:33 -08:00
Dong Chen
68fbfe0cac
change refresh retry count to IntFlag
...
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
2015-11-02 14:42:30 -08:00
Dong Chen
c9f3471dba
add engine options for refresh interval
...
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
2015-10-28 12:56:48 -07:00
Daniel Hiltgen
3661b6e63b
Add TLS support for libkv
...
This adds TLS support into the KV store for swarm. The manage, join,
and list commands all have a new CLI argument, matching the docker engine
discovery backend. This required adding the tlsconfig utility
package from docker engine.
Here's an example showing re-use of the cluster certs for the KV store:
swarm manage --tlsverify \
--tlscacert /etc/docker/ssl/ca.pem
--tlscert /etc/docker/ssl/cert.pem
--tlskey /etc/docker/ssl/key.pem
--discovery-opt kv.cacertfile=/etc/docker/ssl/ca.pem
--discovery-opt kv.certfile=/etc/docker/ssl/cert.pem
--discovery-opt kv.keyfile=/etc/docker/ssl/key.pem
--advertise 192.168.122.47:3376
etcd://192.168.122.47:2379
Signed-off-by: Daniel Hiltgen <daniel.hiltgen@docker.com>
2015-10-12 13:33:08 -07:00
Alexandre Beslic
c74cf900ef
Replace --leaderTTL flag by --replication-ttl
...
Fixes #1256
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-10-02 08:42:14 -07:00
Alexandre Beslic
ab8d1b489c
add support for specifying the leader election lock ttl
...
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-09-23 04:06:35 -07:00
Morgan Bauer
5c4b0a1765
remove deprecated unused flag
...
Signed-off-by: Morgan Bauer <mbauer@us.ibm.com>
2015-09-09 16:22:53 -07:00
Victor Vieux
ec9c970643
update usage
...
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
2015-06-15 14:02:30 -07:00
Andrea Luzzardi
d63de2da48
leader election: Display replica status in docker info.
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-06-11 18:56:02 -07:00
Alexandre Beslic
23f66f8cc6
Merge pull request #858 from aluzzardi/addr-flag
...
Replace --addr with --advertise
2015-05-27 11:44:41 -07:00
Andrea Luzzardi
ad6fac53db
fix --addr backward compatibility
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-26 17:48:54 -07:00
Andrea Luzzardi
7394be0704
Replace --addr with --advertise
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-26 17:43:14 -07:00
Victor Vieux
9ff9bd16ae
add warning and rename flag
...
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
2015-05-26 17:03:08 -07:00
Isabel Jimenez
db7d918c0a
Addressing review comments
...
Signed-off-by: Isabel Jimenez <contact.isabeljimenez@gmail.com>
2015-05-26 19:45:10 -04:00
Isabel Jimenez
920897defb
disable mesos in the cli
...
Signed-off-by: Isabel Jimenez <contact.isabeljimenez@gmail.com>
2015-05-26 16:23:08 -04:00
Victor Vieux
300932b2d5
add slave_test.go, add tast_test.go
...
add basic network mode support
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
Signed-off-by: Isabel Jimenez <contact.isabeljimenez@gmail.com>
Signed-off-by: Timothy Chen <tnachen@gmail.com>
2015-05-26 16:22:34 -04:00
Isabel Jimenez
18235bee97
cluster mesos with engine
...
Signed-off-by: Timothy Chen <tnachen@gmail.com>
Signed-off-by: Isabel Jimenez <contact.isabeljimenez@gmail.com>
Signed-off-by: Victor Vieux <vieux@docker.com>
2015-05-26 16:18:33 -04:00
Andrea Luzzardi
b4efc08dfc
api: Integrate leader election.
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-22 21:23:34 -07:00
Alexandre Beslic
b8d72c291d
Cleanup, fix Integration tests and use of a single global Session in Consul
...
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-05-19 15:27:39 -07:00
Alexandre Beslic
f81de46ab4
Fix Consul and etcd with latest changes, use etcd v2.0.11 for integration tests, remove call to SyncCluster for now (breaks the integration tests)
...
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-05-19 10:25:31 -07:00
Andrea Luzzardi
3d6f833f6f
fix --heartbeat flag.
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-18 13:38:15 -07:00
Andrea Luzzardi
0c72bcaf40
discovery cleanup: heartbeat is a time.Duration.
...
- Use a time.Duration instead of a uint64 for hb
- Flags can accept durations: --heartbeat 25s
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-18 13:38:14 -07:00
Andrea Luzzardi
f33c03af93
discovery: Push watch errors to a channel
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-18 13:38:14 -07:00
Victor Vieux
c29404e272
add --cluster-driver and --cluster-opt
...
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
2015-05-12 17:49:00 -07:00
Andrea Luzzardi
eebc06aabe
Cleanup: Move CLI related files to a subpackage.
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-04-18 20:26:55 -07:00