middleware

package
v0.18.0 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2022 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Metrics

func Metrics(next http.Handler) http.Handler

Metrics is middleware which provides tracking of key metrics for incoming HTTP requests.

Types

type Logging

type Logging struct {
	Logger log.Logger
}

func (Logging) Requests

func (l Logging) Requests(next http.Handler) http.Handler

Requests is middleware to create a request specific logger, passing in through the request's context, as well as loggin the incoming request.

type Recover

type Recover struct {
	Logger log.Logger
}

func (Recover) Panics

func (m Recover) Panics(next http.Handler) http.Handler

Panics is middleware for recovering and reporting panics.

Jump to

Keyboard shortcuts

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