Documentation ¶
Index ¶
- func NewClient(cfg Config) (*memcache.Client, error)
- type Client
- type Config
- type MeasuredClient
- func (mc *MeasuredClient) Add(item *memcache.Item) (err error)
- func (mc *MeasuredClient) CompareAndSwap(item *memcache.Item) (err error)
- func (mc *MeasuredClient) Delete(key string) (err error)
- func (mc *MeasuredClient) Get(key string) (item *memcache.Item, err error)
- func (mc *MeasuredClient) Set(item *memcache.Item) (err error)
- type Recorder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client interface { Get(key string) (item *memcache.Item, err error) Add(item *memcache.Item) error Set(item *memcache.Item) error CompareAndSwap(item *memcache.Item) error Delete(key string) error }
Client is an interface abstraction for *memcache.Client that has a mock
type Config ¶
type Config struct { Timeout time.Duration `yaml:"timeout"` MaxIdleConns int `yaml:"max_idle_conns"` Servers flagext.StringSlice `yaml:"servers"` }
func (*Config) RegisterFlags ¶
type MeasuredClient ¶
type MeasuredClient struct {
// contains filtered or unexported fields
}
func (*MeasuredClient) CompareAndSwap ¶
func (mc *MeasuredClient) CompareAndSwap(item *memcache.Item) (err error)
func (*MeasuredClient) Delete ¶
func (mc *MeasuredClient) Delete(key string) (err error)
type Recorder ¶
type Recorder interface {
// contains filtered or unexported methods
}
func NewRecorder ¶
func NewRecorder(reg prometheus.Registerer) Recorder
Source Files ¶
Click to show internal directories.
Click to hide internal directories.