|
@@ -41,6 +41,8 @@ func Test_newCluster(t *testing.T) {
|
|
|
Name: "s1",
|
|
Name: "s1",
|
|
|
DataDir: "/tmp/etcd-agent-data-1/etcd.data",
|
|
DataDir: "/tmp/etcd-agent-data-1/etcd.data",
|
|
|
WALDir: "/tmp/etcd-agent-data-1/etcd.data/member/wal",
|
|
WALDir: "/tmp/etcd-agent-data-1/etcd.data/member/wal",
|
|
|
|
|
+ HeartbeatIntervalMs: 100,
|
|
|
|
|
+ ElectionTimeoutMs: 1000,
|
|
|
ListenClientURLs: []string{"http://127.0.0.1:1379"},
|
|
ListenClientURLs: []string{"http://127.0.0.1:1379"},
|
|
|
AdvertiseClientURLs: []string{"http://127.0.0.1:1379"},
|
|
AdvertiseClientURLs: []string{"http://127.0.0.1:1379"},
|
|
|
ListenPeerURLs: []string{"http://127.0.0.1:1380"},
|
|
ListenPeerURLs: []string{"http://127.0.0.1:1380"},
|
|
@@ -68,6 +70,8 @@ func Test_newCluster(t *testing.T) {
|
|
|
Name: "s2",
|
|
Name: "s2",
|
|
|
DataDir: "/tmp/etcd-agent-data-2/etcd.data",
|
|
DataDir: "/tmp/etcd-agent-data-2/etcd.data",
|
|
|
WALDir: "/tmp/etcd-agent-data-2/etcd.data/member/wal",
|
|
WALDir: "/tmp/etcd-agent-data-2/etcd.data/member/wal",
|
|
|
|
|
+ HeartbeatIntervalMs: 100,
|
|
|
|
|
+ ElectionTimeoutMs: 1000,
|
|
|
ListenClientURLs: []string{"http://127.0.0.1:2379"},
|
|
ListenClientURLs: []string{"http://127.0.0.1:2379"},
|
|
|
AdvertiseClientURLs: []string{"http://127.0.0.1:2379"},
|
|
AdvertiseClientURLs: []string{"http://127.0.0.1:2379"},
|
|
|
ListenPeerURLs: []string{"http://127.0.0.1:2380"},
|
|
ListenPeerURLs: []string{"http://127.0.0.1:2380"},
|
|
@@ -95,6 +99,8 @@ func Test_newCluster(t *testing.T) {
|
|
|
Name: "s3",
|
|
Name: "s3",
|
|
|
DataDir: "/tmp/etcd-agent-data-3/etcd.data",
|
|
DataDir: "/tmp/etcd-agent-data-3/etcd.data",
|
|
|
WALDir: "/tmp/etcd-agent-data-3/etcd.data/member/wal",
|
|
WALDir: "/tmp/etcd-agent-data-3/etcd.data/member/wal",
|
|
|
|
|
+ HeartbeatIntervalMs: 100,
|
|
|
|
|
+ ElectionTimeoutMs: 1000,
|
|
|
ListenClientURLs: []string{"http://127.0.0.1:3379"},
|
|
ListenClientURLs: []string{"http://127.0.0.1:3379"},
|
|
|
AdvertiseClientURLs: []string{"http://127.0.0.1:3379"},
|
|
AdvertiseClientURLs: []string{"http://127.0.0.1:3379"},
|
|
|
ListenPeerURLs: []string{"http://127.0.0.1:3380"},
|
|
ListenPeerURLs: []string{"http://127.0.0.1:3380"},
|