filters

package
v0.0.0-...-0edc9b0 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RateLimitFilter

type RateLimitFilter struct {
	RequestLimit int
	BurstLimit   int
	// contains filtered or unexported fields
}

func NewRateLimitFilter

func NewRateLimitFilter(requestLimit, burstLimit int, excludePattern string) (*RateLimitFilter, error)

func (*RateLimitFilter) PeriodicCleanup

func (r *RateLimitFilter) PeriodicCleanup(ctx context.Context)

func (*RateLimitFilter) WithRateLimitAuthenticatedUser

func (r *RateLimitFilter) WithRateLimitAuthenticatedUser(handler http.Handler) http.Handler

WithRateLimitAuthenticatedUser limits the number of requests per-user

Jump to

Keyboard shortcuts

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