middleware

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Authentication added in v0.0.6

func Authentication(next http.Handler) http.Handler

Authentication middleware validates API keys and manages authentication

func CORS

func CORS(next http.Handler) http.Handler

CORS handles Cross-Origin Resource Sharing

func PanicRecovery

func PanicRecovery(next http.Handler) http.Handler

PanicRecovery recovers from panics and returns a 500 error

func RateLimit added in v0.0.6

func RateLimit(next http.Handler) http.Handler

RateLimit middleware implements a token bucket algorithm for rate limiting

func RequestID

func RequestID(next http.Handler) http.Handler

RequestID generates a unique ID for each request

func RequestTimer

func RequestTimer(next http.Handler) http.Handler

RequestTimer measures request processing time

Types

This section is empty.

Jump to

Keyboard shortcuts

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