From ea2a4387a96d095b41c0b835acedd74296cee4e7 Mon Sep 17 00:00:00 2001 From: Hongchao Deng Date: Fri, 9 Sep 2016 17:06:05 -0700 Subject: [PATCH] remove waitMemberReadyTimeout and use constants.DefaultDialTimeout --- pkg/cluster/reconcile.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/pkg/cluster/reconcile.go b/pkg/cluster/reconcile.go index ece9988..bfb3886 100644 --- a/pkg/cluster/reconcile.go +++ b/pkg/cluster/reconcile.go @@ -3,7 +3,6 @@ package cluster import ( "fmt" "net/http" - "time" log "github.com/Sirupsen/logrus" "github.com/coreos/etcd/clientv3" @@ -13,8 +12,6 @@ import ( "golang.org/x/net/context" ) -const waitMemberReadyTimeout = 10 * time.Second - // reconcile reconciles // - the members in the cluster view with running pods in Kubernetes. // - the members and expect size of cluster. @@ -43,7 +40,7 @@ func (c *Cluster) reconcile(running etcdutil.MemberSet) error { if err != nil { return err } - if err := etcdutil.WaitMemberReady(etcdcli, waitMemberReadyTimeout); err != nil { + if err := etcdutil.WaitMemberReady(etcdcli, constants.DefaultDialTimeout); err != nil { return err } c.updateMembers(etcdcli)