Merge pull request #934 from smarterclayton/make_timeout_longer

Make global http timeout longer than most operations
This commit is contained in:
Daniel Smith 2014-08-18 10:49:16 -07:00
commit 67535ad60f

View File

@ -113,8 +113,8 @@ func main() {
s := &http.Server{ s := &http.Server{
Addr: net.JoinHostPort(*address, strconv.Itoa(int(*port))), Addr: net.JoinHostPort(*address, strconv.Itoa(int(*port))),
Handler: apiserver.Handle(storage, codec, *apiPrefix), Handler: apiserver.Handle(storage, codec, *apiPrefix),
ReadTimeout: 10 * time.Second, ReadTimeout: 5 * time.Minute,
WriteTimeout: 10 * time.Second, WriteTimeout: 5 * time.Minute,
MaxHeaderBytes: 1 << 20, MaxHeaderBytes: 1 << 20,
} }
glog.Fatal(s.ListenAndServe()) glog.Fatal(s.ListenAndServe())