Jonathan Boulle
172a32e5e3
etcdserver: correct timeout and streaming handling
...
This reintroduces the 'stream' parameter to support long-lived watch
sessions. These sessions respect a server timeout (set to 5 minutes by
default).
2014-09-24 11:27:36 -07:00
Yicheng Qin
bc7b0108dc
raft: ConfigChange -> ConfChange
2014-09-23 12:02:44 -07:00
Yicheng Qin
d92931853e
raft: Config -> ConfigChange
...
Configure -> ProposeConfigChange
AddNode, RemoveNode -> ApplyConfigChange
2014-09-22 23:39:53 -07:00
Yicheng Qin
ec8f493fde
raft: refine comments for Configure
2014-09-22 15:44:47 -07:00
Yicheng Qin
dc36ae7058
raft: use pb.Config instead of []byte for Configure
2014-09-22 15:44:47 -07:00
Yicheng Qin
4203569da2
etcdserver: use ConfigType in protobuf
2014-09-22 15:44:46 -07:00
Yicheng Qin
b82d70871f
raft: use EntryType in protobuf
2014-09-22 15:44:46 -07:00
Yicheng Qin
abdb2cad15
etcdserver: Config.Id -> Config.ID
2014-09-22 15:44:46 -07:00
Yicheng Qin
aaffb9eb78
etcdserver: add AddNode, RemoveNode
...
AddNode and RemoveNode is used to propose config change to the cluster.
If succeeds, it will add/remove node from the cluster.
2014-09-22 15:44:46 -07:00
Brian Waldon
7d1126fb35
etcdserver: init time.Time only if Expiration > 0
...
golang's concept of "zero" time does not align with the zero value of
a unix timestamp. Initializing time.Time with a unix timestamp of 0
makes time.Time.IsZero fail. Solve this by initializing time.Time only
if we care about the time.
2014-09-22 15:31:31 -07:00
Jonathan Boulle
e08df4c8d2
store: fix recursive/dir arguments
2014-09-22 14:44:01 -07:00
Brian Waldon
91003cb994
*: s/prevExists/prevExist/
2014-09-18 21:25:08 -07:00
Jonathan Boulle
a42d52482c
etcdserver: use simple PRNG for GenID
2014-09-17 15:29:14 -07:00
Xiang Li
ab61a8aa9a
*: init for on disk snap support
2014-09-17 13:56:12 -07:00
Yicheng Qin
023dc7cba2
etcdserver: add SYNC request
2014-09-16 13:42:03 -07:00
Jonathan Boulle
8a5ab2ec06
etcdserver: introduce Server interface
...
This changes etcdserver.Server to an interface, with the former Server
(now "EtcdServer") becoming the canonical/production implementation.
This will facilitate better testing of the http server et al with mock
implementations of the interface.
It also more clearly defines the boundary for users of the Server.
2014-09-15 15:11:01 -07:00
Yicheng Qin
6cd4434ff3
server: add unit tests
...
Make test coverage >= 90%
2014-09-15 13:16:48 -07:00
Jonathan Boulle
f7444ff300
store: convert Watch to interface
2014-09-09 11:17:53 -07:00
Blake Mizerany
d844377ca6
*: vendor context
2014-09-03 20:06:16 -07:00
Xiang Li
2ba57ee75d
*: remove unused pkgs
2014-09-03 09:20:20 -07:00