Documentation ¶
Index ¶
- type CacheHandler
- func (ch *CacheHandler) DeleteMulti(ctx context.Context, keys []datastore.Key) error
- func (ch *CacheHandler) DeleteMultiWithTx(info *datastore.MiddlewareInfo, keys []datastore.Key) error
- func (ch *CacheHandler) DeleteMultiWithoutTx(info *datastore.MiddlewareInfo, keys []datastore.Key) error
- func (ch *CacheHandler) GetAll(info *datastore.MiddlewareInfo, q datastore.Query, qDump *datastore.QueryDump, ...) ([]datastore.Key, error)
- func (ch *CacheHandler) GetMulti(ctx context.Context, keys []datastore.Key) ([]*storagecache.CacheItem, error)
- func (ch *CacheHandler) GetMultiWithTx(info *datastore.MiddlewareInfo, keys []datastore.Key, ...) error
- func (ch *CacheHandler) GetMultiWithoutTx(info *datastore.MiddlewareInfo, keys []datastore.Key, ...) error
- func (ch *CacheHandler) Next(info *datastore.MiddlewareInfo, q datastore.Query, qDump *datastore.QueryDump, ...) (datastore.Key, error)
- func (ch *CacheHandler) PostCommit(info *datastore.MiddlewareInfo, tx datastore.Transaction, ...) error
- func (ch *CacheHandler) PostRollback(info *datastore.MiddlewareInfo, tx datastore.Transaction) error
- func (ch *CacheHandler) Printf(ctx context.Context, format string, args ...interface{})
- func (ch *CacheHandler) PutMultiWithTx(info *datastore.MiddlewareInfo, keys []datastore.Key, ...) ([]datastore.PendingKey, error)
- func (ch *CacheHandler) PutMultiWithoutTx(info *datastore.MiddlewareInfo, keys []datastore.Key, ...) ([]datastore.Key, error)
- func (ch *CacheHandler) Run(info *datastore.MiddlewareInfo, q datastore.Query, qDump *datastore.QueryDump) datastore.Iterator
- func (ch *CacheHandler) SetMulti(ctx context.Context, cis []*storagecache.CacheItem) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CacheHandler ¶
type CacheHandler struct { ExpireDuration time.Duration KeyPrefix string Logf func(ctx context.Context, format string, args ...interface{}) // contains filtered or unexported fields }
func New ¶
func New(conn redis.Conn, opts ...storagecache.CacheOption) *CacheHandler
func (*CacheHandler) DeleteMulti ¶
func (*CacheHandler) DeleteMultiWithTx ¶
func (ch *CacheHandler) DeleteMultiWithTx(info *datastore.MiddlewareInfo, keys []datastore.Key) error
func (*CacheHandler) DeleteMultiWithoutTx ¶
func (ch *CacheHandler) DeleteMultiWithoutTx(info *datastore.MiddlewareInfo, keys []datastore.Key) error
func (*CacheHandler) GetAll ¶
func (ch *CacheHandler) GetAll(info *datastore.MiddlewareInfo, q datastore.Query, qDump *datastore.QueryDump, psList *[]datastore.PropertyList) ([]datastore.Key, error)
func (*CacheHandler) GetMulti ¶
func (ch *CacheHandler) GetMulti(ctx context.Context, keys []datastore.Key) ([]*storagecache.CacheItem, error)
func (*CacheHandler) GetMultiWithTx ¶
func (ch *CacheHandler) GetMultiWithTx(info *datastore.MiddlewareInfo, keys []datastore.Key, psList []datastore.PropertyList) error
func (*CacheHandler) GetMultiWithoutTx ¶
func (ch *CacheHandler) GetMultiWithoutTx(info *datastore.MiddlewareInfo, keys []datastore.Key, psList []datastore.PropertyList) error
func (*CacheHandler) Next ¶
func (ch *CacheHandler) Next(info *datastore.MiddlewareInfo, q datastore.Query, qDump *datastore.QueryDump, iter datastore.Iterator, ps *datastore.PropertyList) (datastore.Key, error)
func (*CacheHandler) PostCommit ¶
func (ch *CacheHandler) PostCommit(info *datastore.MiddlewareInfo, tx datastore.Transaction, commit datastore.Commit) error
func (*CacheHandler) PostRollback ¶
func (ch *CacheHandler) PostRollback(info *datastore.MiddlewareInfo, tx datastore.Transaction) error
func (*CacheHandler) Printf ¶
func (ch *CacheHandler) Printf(ctx context.Context, format string, args ...interface{})
func (*CacheHandler) PutMultiWithTx ¶
func (ch *CacheHandler) PutMultiWithTx(info *datastore.MiddlewareInfo, keys []datastore.Key, psList []datastore.PropertyList) ([]datastore.PendingKey, error)
func (*CacheHandler) PutMultiWithoutTx ¶
func (ch *CacheHandler) PutMultiWithoutTx(info *datastore.MiddlewareInfo, keys []datastore.Key, psList []datastore.PropertyList) ([]datastore.Key, error)
func (*CacheHandler) Run ¶
func (ch *CacheHandler) Run(info *datastore.MiddlewareInfo, q datastore.Query, qDump *datastore.QueryDump) datastore.Iterator
func (*CacheHandler) SetMulti ¶
func (ch *CacheHandler) SetMulti(ctx context.Context, cis []*storagecache.CacheItem) error
Click to show internal directories.
Click to hide internal directories.