about summary refs log tree commit diff
path: root/tvix/nar-bridge/pkg/server/server.go
diff options
context:
space:
mode:
authorFlorian Klink <flokli@flokli.de>2022-11-27T10·08+0000
committerflokli <flokli@flokli.de>2023-09-17T13·24+0000
commit5841047c38fdd9eb822151e8ce6142da90aa4849 (patch)
treee5cd7f08f0791c147af8aae72f6edb5d50b7ac9d /tvix/nar-bridge/pkg/server/server.go
parent0ecd10bf307049b9833e69f331ec049ae8840d85 (diff)
feat(tvix/nar-bridge): increase timeouts r/6601
In some cases, Nix is not able to stream the NAR file fast enough. Bump the
timeouts for now. We might want to get a better understanding in what's
happening here long-term, and/or make the timeouts configurable.

Change-Id: Ieaa9c8f04bc73c6ce0679a058d07eaf87126634e
Reviewed-on: https://cl.tvl.fyi/c/depot/+/9340
Reviewed-by: tazjin <tazjin@tvl.su>
Tested-by: BuildkiteCI
Diffstat (limited to 'tvix/nar-bridge/pkg/server/server.go')
-rw-r--r--tvix/nar-bridge/pkg/server/server.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/tvix/nar-bridge/pkg/server/server.go b/tvix/nar-bridge/pkg/server/server.go
index 083b7f295a12..0de38c84dfee 100644
--- a/tvix/nar-bridge/pkg/server/server.go
+++ b/tvix/nar-bridge/pkg/server/server.go
@@ -77,9 +77,9 @@ func (s *Server) ListenAndServe(addr string) error {
 	srv := &http.Server{
 		Addr:         addr,
 		Handler:      s.handler,
-		ReadTimeout:  50 * time.Second,
-		WriteTimeout: 100 * time.Second,
-		IdleTimeout:  150 * time.Second,
+		ReadTimeout:  500 * time.Second,
+		WriteTimeout: 500 * time.Second,
+		IdleTimeout:  500 * time.Second,
 	}
 
 	return srv.ListenAndServe()