mirror of
https://github.com/pgsty/minio.git
synced 2026-08-08 23:33:30 +03:00
Adding error message on connection limit met
This commit is contained in:
@@ -61,6 +61,8 @@ func (c *connLimit) ServeHTTP(w http.ResponseWriter, req *http.Request) {
|
||||
if c.TestAndAdd(longIP) {
|
||||
defer c.Remove(longIP)
|
||||
c.handler.ServeHTTP(w, req)
|
||||
} else {
|
||||
writeErrorResponse(w, req, ConnectionLimitExceeded, req.RequestURI)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user