Andrea Luzzardi
c77f7332a0
store: Fixes to etcd and zk WatchTree
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-15 13:37:51 -07:00
Andrea Luzzardi
7d7e4aee13
store: Watch: Use channels instead of callbacks.
...
This gets rid of `CancelWatch*` functions and its usage is much simpler.
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-15 13:37:51 -07:00
Andrea Luzzardi
0f61855877
store: Get rid of "discovery" log messages
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-14 22:35:14 -07:00
Andrea Luzzardi
a897fa04d5
store: Watch/WatchTree: Removed unused params
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-14 22:25:26 -07:00
Andrea Luzzardi
f87505e2e7
store: KVEntry -> KVPair
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-14 22:00:27 -07:00
Andrea Luzzardi
895484ec2a
store: WatchRange -> WatchTree
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-14 21:58:02 -07:00
Andrea Luzzardi
6f41eabdae
store: GetRange -> List
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-14 21:58:02 -07:00
Andrea Luzzardi
d4bdb10d35
store: Make KVEntry a struct rather than an interface.
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-14 21:58:02 -07:00
Andrea Luzzardi
747a83a40a
store: Cleanup initializers.
...
- KV is now Backend
- name (string) is now backend (Backend)
- initializers are now a static var rather than generated by init()
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-14 21:32:10 -07:00
Kelsey Hightower
0d87489773
discovery: improve code comments.
...
Signed-off-by: Kelsey Hightower <kelsey.hightower@gmail.com>
2015-05-14 08:49:40 -07:00
Andrea Luzzardi
9d055d6bf8
pkg/store: Pass Options as pointer, not value.
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-05-13 19:00:39 -07:00
Victor Vieux
0b45fa5154
user varargs in store the watch callback
...
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
2015-05-13 15:42:44 -07:00
Madhu Venugopal
0130c2262d
GetRange and WatchRange to return {key,value,index} tuple
...
Signed-off-by: Madhu Venugopal <madhu@docker.com>
2015-05-13 11:24:03 -07:00
Alexandre Beslic
06f51e09b0
revert variable names
...
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-05-12 14:47:48 -07:00
Alexandre Beslic
403f95f86c
Remove placeholder TLS parameter in discovery interface and New method
...
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-05-12 14:19:30 -07:00
Alexandre Beslic
6f67ca3a58
replace variadic method options for simple Config struct, correct Consul Watch method
...
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-05-12 14:00:55 -07:00
Alexandre Beslic
e039563c78
Fix zookeeper timeout value
...
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-05-11 18:23:40 -07:00
Alexandre Beslic
59e1e9b942
Change existing discovery backends to 'kv' using metatada storage backends in the store package
...
Signed-off-by: Alexandre Beslic <abronan@docker.com>
2015-05-11 17:23:55 -07:00
Andrea Luzzardi
d492feb7cc
golint: DiscoveryService -> Discovery
...
Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
2015-04-15 14:26:39 -07:00
Kushal Pisavadia
78dba5d623
Remove prefixes from DiscoveryService implementations
...
All of these structs are public. Previously when they were used, they'd
look like the following:
- `consul.ConsulDiscoveryService`
- `etcd.EtcdDiscoveryService`
- `file.FileDiscoveryService`
- `nodes.NodesDiscoveryService`
- `token.TokenDiscoveryService`
- `zookeeper.ZkDiscoveryService`
As a result, they stuttered when read. This commit removes the
duplication of the package names on the struct so that they read better.
See also: https://golang.org/ref/spec#Import_declarations
Signed-off-by: Kushal Pisavadia <kushi.p@gmail.com>
2015-04-15 20:58:17 +01:00
James Turnbull
658c807eb9
Did a quick pass on the docs to fix numerous formatting, spelling and grammar errors
...
Signed-off-by: James Turnbull <james@lovedthanlost.net>
2015-04-14 11:59:50 -04:00
Mike Goelzer
8aa9d20932
Additional unit tests; raises generator.go test coverage to 100%
...
Signed-off-by: Mike Goelzer <mike@goelzer.com>
2015-04-12 08:28:45 -07:00
Sriram Natarajan
b174aa26de
Change heartbeat type to unsigned int
...
Check if heartbeat value is greater than zero
Signed-off-by: Sriram Natarajan <natarajan.sriram@gmail.com>
2015-04-09 00:04:50 +00:00
jangelfdez
17b9b96b33
Doc changed to avoid errors with POST calls to Docker Hub Discovery Service API
...
The data on the "Add new nodes to a cluster" request may be confusing. It's not a key=value pair as it can be understood with the current docs.
Signed-off-by: jangelfdez <me@joseangelfernandez.es>
2015-04-07 14:36:07 -07:00
Victor Vieux
5e41510484
udpate tests
...
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
2015-04-07 10:41:18 -07:00
Yucong Sun
b45a985b9b
Ignoring # comments in file discovery.
...
Signed-off-by: Yucong Sun <sunyucong@email.com>
2015-04-07 23:11:57 +08:00
Mike Goelzer
bcca57bda8
Make TTL > heartbeat by at least one second to prevent key from disappearing before next heartbeat
...
Signed-off-by: Mike Goelzer <mike@goelzer.com>
2015-04-02 19:34:30 -07:00
Mike Goelzer
5d289e2434
Fixed url of Docker Hub discovery service
...
Signed-off-by: Mike Goelzer <mike@goelzer.com>
2015-04-02 09:50:34 -07:00
Sriram Natarajan
74a9a04a60
Fix discovery token README
...
Signed-off-by: Sriram Natarajan <natarajan.sriram@gmail.com>
2015-04-01 12:09:53 -07:00
Victor Vieux
b655cbb7c5
Merge pull request #514 from technolo-g/Issue_499_Automate_golint_pr
...
Issue #500 Run golint on codebase
2015-03-30 12:14:15 -07:00
Matt Bajor
d87c48ae4e
Fix lint violations
...
This changeset fixes all lint violations that show up with a
min_confidence of 1
- Issue #500 : Run golint on codebase
Signed-off-by: Matt Bajor <matt@notevenremotelydorky.com>
2015-03-27 21:17:44 -06:00
Chanwit Kaewkasi
f1fd1fb145
fix per golint checks
...
Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
2015-03-28 00:52:53 +07:00
Victor Vieux
45fc0c9272
Merge pull request #509 from vieux/nodes-discovery-gen
...
Proposal: implement IP generator for nodes and file discoveries by @chanwit
2015-03-24 17:00:48 -06:00
Victor Vieux
24093beb85
add quotes in doc
...
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
2015-03-24 16:49:18 -06:00
Victor Vieux
421c5a2ee5
add https to token doc
...
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
2015-03-18 17:01:40 -07:00
Chanwit Kaewkasi
92ef21d2ec
explain ip generator in discovery/README
...
Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
2015-03-12 15:50:00 +07:00
Chanwit Kaewkasi
882be558e8
add ip generator for file
...
Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
2015-03-12 15:49:58 +07:00
Chanwit Kaewkasi
09b8eb8564
implement ip generator for nodes
...
Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
2015-03-12 15:49:56 +07:00
Sven Dowideit
c530cd1523
add an index and go make some small tweaks
...
Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
2015-02-26 11:19:14 +10:00
Ferran Rodenas
cecdd7df02
Ignore empty addresses when creating discovery entries
...
Signed-off-by: Ferran Rodenas <frodenas@gmail.com>
2015-02-24 22:10:31 -08:00
Victor Vieux
ff22cbc2d3
fix panic in token discovery
...
Signed-off-by: Victor Vieux <vieux@docker.com>
2015-02-18 22:08:07 -08:00
JChien
a19fecee87
update import url
...
Signed-off-by: JChien <jeffchien13@gmail.com>
2015-02-11 21:25:55 +08:00
Victor Vieux
3df8bbed61
refactor createEntries
...
Signed-off-by: Victor Vieux <vieux@docker.com>
2015-02-10 02:25:38 +00:00
Victor Vieux
ba01634743
replace discovery.Node by discovery.Entry
...
Signed-off-by: Victor Vieux <vieux@docker.com>
2015-02-10 01:58:43 +00:00
Victor Vieux
afed2abbea
update swarm manage requirements again
...
Signed-off-by: Victor Vieux <vieux@docker.com>
2015-02-03 01:57:13 +00:00
Victor Vieux
aaac7cbb94
update swarm manage requirements
...
Signed-off-by: Victor Vieux <vieux@docker.com>
2015-02-02 18:34:24 +00:00
Victor Vieux
bcc9f8b7c6
Merge pull request #343 from mota/fix-token-leak
...
Force connection close with token discovery
2015-02-02 10:18:31 -08:00
Sven Dowideit
14c4fb81cf
Add docker.docker.com metadata and reflow to 80-chars for GH diffs
...
Signed-off-by: Sven Dowideit <SvenDowideit@docker.com>
2015-02-02 09:53:43 +10:00
Pierre Wacrenier
e3bf42d5be
Force connection close with token discovery
...
Signed-off-by: Pierre Wacrenier <pierre.wacrenier@gmail.com>
2015-02-01 05:48:30 +01:00
Victor Vieux
29bfee02fe
error when token is empty
...
Signed-off-by: Victor Vieux <vieux@docker.com>
2015-01-30 22:42:18 +00:00