middleware

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2022 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ContentType

func ContentType() func(http.Handler) http.Handler

ContentType currently sets the content-type only for eventSchemas, health responses. Note : responses via http.Error aren't affected. They default to text/plain

func LimitConcurrentRequests

func LimitConcurrentRequests(maxRequests int) func(http.Handler) http.Handler

this is to make sure that we don't have more than `maxClient` in-memory at any point of time. As, having more http client than `maxClient` may lead to gateway OOM kill.

func StatMiddleware

func StatMiddleware(ctx context.Context) func(http.Handler) http.Handler

Types

This section is empty.

Jump to

Keyboard shortcuts

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