etcdserver: print out initial cluster members

It is moved from etcdmain pkg because the line should only be printed out
when etcd bootstraps at the first time.
This commit is contained in:
Yicheng Qin 2014-11-03 19:22:05 -08:00
parent d1ec13210f
commit 5ed5d44652
2 changed files with 1 additions and 1 deletions

View File

@ -151,7 +151,6 @@ func startEtcd() {
if err != nil {
log.Fatalf("etcd: error setting up initial cluster: %v", err)
}
log.Printf("etcd: initial cluster members: %s", cls.String())
if *dir == "" {
*dir = fmt.Sprintf("%v.etcd", *name)

View File

@ -216,6 +216,7 @@ func NewServer(cfg *ServerConfig) *EtcdServer {
}
}
cfg.Cluster.SetStore(st)
log.Printf("etcdserver: initial cluster members: %s", cfg.Cluster)
id, n, w = startNode(cfg, cfg.Cluster.MemberIDs())
case haveWAL:
if cfg.ShouldDiscover() {