mid

package
v1.2.9 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2024 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AccessLogHandler added in v1.2.0

func AccessLogHandler(logger *slog.Logger, msg string) gin.HandlerFunc

AccessLogHandler records each http request into log

func CorsHandler

func CorsHandler(corsHelper *cors.Cors) gin.HandlerFunc

CorsHandler deals with case of cors origins

func MethodAllowHandler

func MethodAllowHandler() gin.HandlerFunc

MethodAllowHandler deals with case of method not allowed

func RecoveryHandler added in v1.2.0

func RecoveryHandler(logger *slog.Logger) gin.HandlerFunc

RecoveryHandler handles the case of panic situation

func RequestIdHandler added in v1.2.0

func RequestIdHandler() gin.HandlerFunc

RequestIdHandler generates a unique request id for each http request

func ResourceNotFoundHandler

func ResourceNotFoundHandler() gin.HandlerFunc

ResourceNotFoundHandler deals with case of 404

Types

This section is empty.

Jump to

Keyboard shortcuts

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