Skip to content

Commit 71ec1db

Browse files
committed
Adds 60 second read/write timeout to Revel http.server
1 parent 12e1fd9 commit 71ec1db

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

server.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,10 @@ func Run(port int) {
9494
}
9595

9696
Server = &http.Server{
97-
Addr: localAddress,
98-
Handler: http.HandlerFunc(handle),
97+
Addr: localAddress,
98+
Handler: http.HandlerFunc(handle),
99+
ReadTimeout: time.Minute,
100+
WriteTimeout: time.Minute,
99101
}
100102

101103
runStartupHooks()

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy