mirror of
https://github.com/labstack/echo.git
synced 2025-01-12 01:22:21 +02:00
Using read/write timeout in server config
Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
parent
6e183fd3d8
commit
1ca76e5e88
@ -84,6 +84,8 @@ func WithConfig(c engine.Config) (s *Server) {
|
|||||||
}),
|
}),
|
||||||
logger: glog.New("echo"),
|
logger: glog.New("echo"),
|
||||||
}
|
}
|
||||||
|
s.ReadTimeout = c.ReadTimeout
|
||||||
|
s.WriteTimeout = c.WriteTimeout
|
||||||
s.Handler = s.ServeHTTP
|
s.Handler = s.ServeHTTP
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -82,6 +82,8 @@ func WithConfig(c engine.Config) (s *Server) {
|
|||||||
}),
|
}),
|
||||||
logger: glog.New("echo"),
|
logger: glog.New("echo"),
|
||||||
}
|
}
|
||||||
|
s.ReadTimeout = c.ReadTimeout
|
||||||
|
s.WriteTimeout = c.WriteTimeout
|
||||||
s.Addr = c.Address
|
s.Addr = c.Address
|
||||||
s.Handler = s
|
s.Handler = s
|
||||||
return
|
return
|
||||||
|
Loading…
Reference in New Issue
Block a user