ratelimit

package
v0.0.0-...-6725582 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BasicMware

func BasicMware(sesExists func(app.Tlbx) bool, sesID func(app.Tlbx) string, cache iredis.Pool, perMinute ...int) func(app.Tlbx)

func MeMware

func MeMware(cache iredis.Pool, perMinute ...int) func(app.Tlbx)

func Mware

func Mware(configs ...func(*Config)) func(app.Tlbx)

func NoMware

func NoMware(cache iredis.Pool, perMinute ...int) func(app.Tlbx)

Types

type Config

type Config struct {
	KeyGen      func(tlbx app.Tlbx) string
	PerMinute   int
	ExitOnError bool
	Pool        iredis.Pool
}

Jump to

Keyboard shortcuts

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