kratos: github.com/go-kratos/kratos/pkg/net/rpc/warden/ratelimiter Index | Files

package ratelimiter

import "github.com/go-kratos/kratos/pkg/net/rpc/warden/ratelimiter"

Index

Package Files

ratelimiter.go

type RateLimiter Uses

type RateLimiter struct {
    // contains filtered or unexported fields
}

RateLimiter bbr middleware.

func New Uses

func New(conf *bbr.Config) (s *RateLimiter)

New return a ratelimit middleware.

func (*RateLimiter) Limit Uses

func (b *RateLimiter) Limit() grpc.UnaryServerInterceptor

Limit is a server interceptor that detects and rejects overloaded traffic.

Package ratelimiter imports 8 packages (graph) and is imported by 2 packages. Updated 2020-04-29. Refresh now. Tools for package owners.