Documentation ¶
Index ¶
- Variables
- type Convertor
- type DataLoader
- type Expires
- type Group
- func (g *Group) Configure(name string, expires *Expires, maxWait int32) *Group
- func (g *Group) Do(ctx context.Context, loaderName string, dist interface{}, args NamedArgs) error
- func (g *Group) DoWithExpires(ctx context.Context, loaderName string, dist interface{}, args NamedArgs, ...) error
- func (g *Group) MakeKey(loaderName, argsName string) string
- func (g *Group) Register(name string, loader DataLoader) *Group
- func (g *Group) SetConvertor(c Convertor) *Group
- func (g *Group) SetRedisStorage(r redis.Cmdable) *Group
- func (g *Group) SetStorage(s Storage) *Group
- func (g *Group) SetStoragePrefix(prefix string) *Group
- type NamedArgs
- type Storage
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrBadCacheValue = errors.New("sha.groupcache: bad cache")
View Source
var ErrEmpty = errors.New("sha.groupcache: empty")
View Source
var ErrRetryAfter = internal.ErrRetryAfter
View Source
var StdJsonConvertor = _StdJsonConvertor{}
Functions ¶
This section is empty.
Types ¶
type DataLoader ¶
type Expires ¶
type Expires struct { Default utils.TomlDuration `json:"default" toml:"default"` Missing utils.TomlDuration `json:"missing" toml:"missing"` }
type Group ¶
type Group struct {
// contains filtered or unexported fields
}
func (*Group) DoWithExpires ¶
func (g *Group) DoWithExpires(ctx context.Context, loaderName string, dist interface{}, args NamedArgs, expires *Expires) error
dist must be a pointer
func (*Group) SetConvertor ¶
func (*Group) SetRedisStorage ¶
func (*Group) SetStorage ¶
func (*Group) SetStoragePrefix ¶
Click to show internal directories.
Click to hide internal directories.