timeout

package
v2.52.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 26, 2024 License: MIT Imports: 6 Imported by: 9

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New deprecated

func New(handler fiber.Handler, timeout time.Duration) fiber.Handler

New wraps a handler and aborts the process of the handler if the timeout is reached.

Deprecated: This implementation contains data race issues. Use NewWithContext instead. Find documentation and sample usage on https://docs.gofiber.io/api/middleware/timeout

func NewWithContext added in v2.44.0

func NewWithContext(h fiber.Handler, t time.Duration, tErrs ...error) fiber.Handler

NewWithContext implementation of timeout middleware. Set custom errors(context.DeadlineExceeded vs) for get fiber.ErrRequestTimeout response.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL