client

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2022 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

func NewClient

func NewClient(cfg conf.ClientConfig, poolSize int) (*Client, error)

func (*Client) Close

func (c *Client) Close()

func (*Client) List

func (c *Client) List(ctx context.Context, name string, ret *pb.LimiterList) error

func (*Client) NewLimiter

func (c *Client) NewLimiter(ctx context.Context, name string, rate int, interval time.Duration) error

func (*Client) RemoveLimiter

func (c *Client) RemoveLimiter(ctx context.Context, name string) error

func (*Client) Take

func (c *Client) Take(ctx context.Context, name string) error

Jump to

Keyboard shortcuts

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