Xiang Li
6f7fd89ba2
Merge pull request #1718 from yichengq/226
...
sender: support elegant stop
2014-11-13 21:29:02 -08:00
Yicheng Qin
12dba7d413
sender: support elegant stop
2014-11-13 17:44:36 -08:00
Xiang Li
e66bda957b
Merge pull request #1714 from xiang90/stop
...
StopNotify
2014-11-13 15:16:52 -08:00
Xiang Li
6a1fe00615
Merge pull request #1704 from xiang90/print_config
...
*: print out configuration when necessary
2014-11-13 14:35:50 -08:00
Yicheng Qin
11f392bdc8
Merge pull request #1708 from yichengq/223
...
etcdserver: validate new node is not registered before in best effort
2014-11-13 14:30:40 -08:00
Xiang Li
b5d480f17a
etcdserver: add StopNotify
2014-11-13 14:16:48 -08:00
Xiang Li
978d0f1ca1
etcdserver: fix TestDoProposalStopped test
...
We start etcd server in this test without the cluster. Sometimes it panics when
accessing the cluster. Most of the time it does not panic, since we can stop the
server fast enough before applying the first configuration change entry.
2014-11-13 14:08:59 -08:00
Xiang Li
fb344bc33f
etcdserver: minor cleanup
2014-11-13 14:01:56 -08:00
Xiang Li
813ff6ba48
Merge pull request #1713 from xiang90/stop
...
etcdserver: fix server.Stop()
2014-11-13 13:58:07 -08:00
Yicheng Qin
ac907d746b
etcdserver: validate new node is not registered before in best effort
2014-11-13 13:56:11 -08:00
Xiang Li
30dfdb0ea9
etcdserver: fix server.Stop()
...
Stop should be idempotent. It should simply send a stop signal to the server.
It is the server's responsibility to stop the go-routines and related components.
2014-11-13 13:47:12 -08:00
Xiang Li
8c4494a39d
Merge pull request #1711 from bdarnell/stable-restart
...
raft: Only call stableTo when we have ready entries or a snapshot.
2014-11-13 12:49:19 -08:00
Yicheng Qin
9716def94b
Merge pull request #1700 from yichengq/222
...
etcdserver: add sender tests
2014-11-13 12:37:29 -08:00
Yicheng Qin
d89bf9f215
etcdserver: add sender tests
2014-11-13 12:29:25 -08:00
Ben Darnell
32824e053c
raft: Only call stableTo when we have ready entries or a snapshot.
...
The first Ready after RestartNode (with no snapshot) will have no
unstable entries, so we don't have the correct prevLastUnstablei
when Advance is called. This would cause raftLog.unstable to move
backwards and previously-stable entries would be returned to
the application again.
This should have been caught by the "unexpected Ready" portion of
TestNodeRestart, but it went unnoticed because the Node's goroutine
takes some time to read from advancec and prepare the write to read to
readyc. Added a small (1ms) delay to all such tests to ensure that the
goroutine has time to enter its select wait.
2014-11-13 14:57:01 -05:00
Xiang Li
8319d4dcbe
Merge pull request #1709 from xiang90/server_id
...
etcdserver: add ID() function to the Server interface.
2014-11-13 11:37:39 -08:00
Xiang Li
d6f40acc86
etcdserver: add ID() function to the Server interface.
2014-11-13 11:37:06 -08:00
Xiang Li
92096dfdc3
*: print out configuration when necessary
2014-11-13 10:46:42 -08:00
Xiang Li
a551b75d96
Merge pull request #1707 from xiang90/wait_pkg
...
pkg/wait: move wait to pkg/wait
2014-11-13 09:31:34 -08:00
Xiang Li
0d18a0f381
pkg/wait: move wait to pkg/wait
2014-11-13 09:11:53 -08:00
Yicheng Qin
23b5bc0dfe
sender: use RoundTripper instead of Client in sender
2014-11-12 21:42:08 -08:00
Yicheng Qin
1e1535e6f9
Merge pull request #1620 from yichengq/204
...
etcdserver: not record attributes when add member
2014-11-12 21:33:53 -08:00
Xiang Li
4adbd821a3
Merge pull request #1706 from xiang90/fix_sender_hub_add
...
etcdserver: do not add/remove/update local member to/from sender hub
2014-11-12 21:29:33 -08:00
Xiang Li
04994048bb
Merge pull request #1702 from xiang90/node_config_propose
...
raft: add a test for proposeConfChange
2014-11-12 21:16:54 -08:00
Xiang Li
ba915ad5a8
etcdserver: do not add/remove/update local member to/from sender hub
2014-11-12 20:45:21 -08:00
Yicheng Qin
0c2b45ddc6
etcdserver: not record attributes when add member
...
There is no need to set attributes value when adding member because new
member will publish the information whenever it starts.
2014-11-12 17:48:15 -08:00
Jonathan Boulle
eb66d2b0eb
Merge pull request #1699 from jonboulle/node_stop
...
raft: block Stop() on n.done, support idempotency
2014-11-12 16:26:54 -08:00
Xiang Li
2a407dadc0
raft: add a test for proposeConfChange
2014-11-12 16:16:26 -08:00
Xiang Li
634011eb8b
Merge pull request #1698 from xiang90/node_propose
...
raft: add a test for node proposal
2014-11-12 16:02:57 -08:00
Jonathan Boulle
2cedf127d4
raft: block Stop() on n.done, support idempotency
2014-11-12 15:54:45 -08:00
Xiang Li
68ab7e69e1
raft: add a test for node proposal
2014-11-12 15:44:24 -08:00
Yicheng Qin
ec7793557a
Merge pull request #1664 from yichengq/212
...
integration: add AddMember test
2014-11-12 15:04:30 -08:00
Xiang Li
b271e88c20
Merge pull request #1696 from xiang90/testnodetick
...
raft: add a test for node.Tick
2014-11-12 14:38:07 -08:00
Yicheng Qin
bc9de47a9a
integration: add increase cluster size test
2014-11-12 14:33:18 -08:00
Jonathan Boulle
fc21f299b1
Merge pull request #1676 from jonboulle/doc_initial_cluster
...
etcdserver: validate and document initial-advertise-peer-urls
2014-11-12 14:13:03 -08:00
Jonathan Boulle
5cef3d888a
integration: remove unnecessary t.Testing argument
2014-11-12 14:11:56 -08:00
Xiang Li
d834324e97
raft: stop the node synchronously
2014-11-12 14:06:52 -08:00
Jonathan Boulle
d1ae276434
integration: fix test to propagate NewServer errors
2014-11-12 13:12:49 -08:00
Jonathan Boulle
1197c1f965
etcdserver: move peer URLs check to config
2014-11-12 13:12:49 -08:00
Jonathan Boulle
3f358b6d5d
etcdserver: ensure initial-advertise-peer-urls match initial-cluster
...
This adds a check to setupCluster to ensure that the list of URLs
specified in `initial-advertise-peer-urls` matches those configured in
`initial-cluster` for this node. Also updates the documentation to
clarify this and address some changes in wording.
2014-11-12 12:54:35 -08:00
Xiang Li
45c36a0808
raft: add a test for node.Tick
2014-11-12 11:51:51 -08:00
Xiang Li
0772987128
Merge pull request #1695 from xiang90/nodestart
...
raft: add comment string for TestNodeStart
2014-11-12 11:41:03 -08:00
Xiang Li
fe0325fce7
raft: add comment string for TestNodeStart
2014-11-12 11:40:40 -08:00
Xiang Li
f1f796f2fc
Merge pull request #1694 from xiang90/use_member
...
etcdserver: use member instead of node at etcd level
2014-11-12 10:48:45 -08:00
Xiang Li
0aa8258d29
etcdserver: use member instead of node at etcd level
2014-11-12 10:45:35 -08:00
Yicheng Qin
fb93e3fa00
Merge pull request #1689 from yichengq/219
...
raft: update unstable when calling stableTo with 0
2014-11-12 10:41:40 -08:00
Xiang Li
d494014782
Merge pull request #1679 from xiang90/peerurl
...
update peer url
2014-11-12 10:21:13 -08:00
Yicheng Qin
48644f465d
Merge pull request #1692 from yichengq/221
...
raft: nodes return sorted ids
2014-11-12 10:08:19 -08:00
Yicheng Qin
78cbb1512c
raft: nodes return sorted ids
...
This makes raft.softState return the same result when its soft state is
not changed.
2014-11-11 22:58:15 -08:00
Yicheng Qin
7dba92dd53
raft: update unstable when calling stableTo with 0
...
It should update unstable in this case because it may happen that raft
only writes entry 0 into stable storage.
2014-11-11 17:20:31 -08:00