middleware

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Authorize added in v1.2.1

func Authorize(authorizer authz.Authorizer) echo.MiddlewareFunc

Authorize only allows the HTTP request to continue if the passed authorizer permits the request.

func ChainedSkipper added in v1.2.2

func ChainedSkipper(skippers ...echomiddelware.Skipper) echomiddelware.Skipper

ChainedSkipper creates a skipper that skips if any of the provided skippers returns true

func Otel

func Otel() echo.MiddlewareFunc

func PathMatchSkipper

func PathMatchSkipper(paths []string) echomiddelware.Skipper

func RequestLogger

func RequestLogger(logger zerolog.Logger, logLevel zerolog.Level) echo.MiddlewareFunc

func ServerHeader added in v1.2.1

func ServerHeader(headers map[string]string) echo.MiddlewareFunc

ServerHeader middleware adds HTTP Headers `headers` to response

func SetContentType

func SetContentType(contentType string) echo.MiddlewareFunc

SetContentType returns a middleware which sets the response content type.

func VersionNotifyLogger added in v1.2.1

func VersionNotifyLogger(logger *zerolog.Logger, serverVersion semver.Version) echo.MiddlewareFunc

func WebsocketSkipper added in v1.2.2

func WebsocketSkipper(c echo.Context) bool

Types

type Notification added in v1.2.1

type Notification struct {
	RequestID     string
	ClientID      string
	ServerVersion string

	ClientVersion string
	Message       string
}

Jump to

Keyboard shortcuts

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