Skip to content
This repository has been archived by the owner on Nov 30, 2021. It is now read-only.

Commit

Permalink
fix(logspout): add etcd client request timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew Fisher committed Oct 6, 2014
1 parent 1280daf commit 15b0843
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions logspout/logspout.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import (
"os"
"strconv"
"strings"
"time"

"code.google.com/p/go.net/websocket"
"github.com/coreos/go-etcd/etcd"
Expand Down Expand Up @@ -143,6 +144,7 @@ func main() {
connectionString := []string{"http://" + etcdHost + ":4001"}
debug("etcd:", connectionString[0])
etcd := etcd.NewClient(connectionString)
etcd.SetDialTimeout(3 * time.Second)
hostResp, err := etcd.Get("/deis/logs/host", false, false)
assert(err, "url")
portResp, err := etcd.Get("/deis/logs/port", false, false)
Expand Down

0 comments on commit 15b0843

Please sign in to comment.