Documentation ¶
Index ¶
- Variables
- type Client
- func (c *Client) Del(k string) error
- func (c *Client) Get(k string, v interface{}) error
- func (c *Client) NewMutex(ctx context.Context) *Mutex
- func (c *Client) NewMutexWithOptions(ctx context.Context, o MutexOptions) *Mutex
- func (c *Client) Set(k string, v interface{}, ttl time.Duration) error
- func (c *Client) SetNX(k string, v interface{}, ttl time.Duration) (bool, error)
- type Configuration
- type Mutex
- type MutexOptions
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Addr = flag.String("redis-addr", "", "the redis addr") Prefix = flag.String("redis-prefix", "", "the redis prefix") )
Flags
View Source
var Nil = redis.Nil
Nil error
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client represents a client
func (*Client) NewMutexWithOptions ¶
func (c *Client) NewMutexWithOptions(ctx context.Context, o MutexOptions) *Mutex
NewMutexWithOptions creates a new mutex with options
type Configuration ¶
Configuration represents the configuration of the proxy
func FlagConfig ¶
func FlagConfig() Configuration
FlagConfig generates a Configuration based on flags
Click to show internal directories.
Click to hide internal directories.