middleware

package
v0.15.2 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2023 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CORS

CORS is a middleware for handling CORS requests.

func Metrics

func Metrics(path string, options ...MetricsOption) azugo.RequestHandlerFunc

Metrics initializes and returns Prometheus metrics middleware

func RealIP

RealIP middleware updates request remote IP address based on X-Real-IP and X-Forwarded-For headers.

func RequestLogger

func RequestLogger(next azugo.RequestHandler) azugo.RequestHandler

Types

type MetricsOption

type MetricsOption interface {
	// contains filtered or unexported methods
}

Interface for metrics handler options

type MetricsSubsystem

type MetricsSubsystem string

MetricsSubsystem represents subsystem name for Prometheus metric structuring

Jump to

Keyboard shortcuts

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