Skip to content

Commit 10d8c53

Browse files
authored
Fix timeout middleware docs (fixes #1816) (#1836)
1 parent ae4665c commit 10d8c53

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

middleware/timeout.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ var (
4242
}
4343
)
4444

45-
// Timeout returns a middleware which recovers from panics anywhere in the chain
46-
// and handles the control to the centralized HTTPErrorHandler.
45+
// Timeout returns a middleware which returns error (503 Service Unavailable error) to client immediately when handler
46+
// call runs for longer than its time limit. NB: timeout does not stop handler execution.
4747
func Timeout() echo.MiddlewareFunc {
4848
return TimeoutWithConfig(DefaultTimeoutConfig)
4949
}

0 commit comments

Comments
 (0)