Documentation
¶
Overview ¶
Package redisstore implements the scs.Store interface on top of Redis. It exists (rather than using scs's own redisstore) so the keys carry the cms_session: prefix and can live in a Redis instance shared with the host application, mirroring what sessionstore does for the cms_sessions table.
Redis expires keys itself, so unlike sessionstore there is no background cleanup goroutine.
Index ¶
- type Store
- func (s *Store) Commit(token string, data []byte, expiry time.Time) error
- func (s *Store) CommitCtx(ctx context.Context, token string, data []byte, expiry time.Time) error
- func (s *Store) Delete(token string) error
- func (s *Store) DeleteCtx(ctx context.Context, token string) error
- func (s *Store) Find(token string) ([]byte, bool, error)
- func (s *Store) FindCtx(ctx context.Context, token string) ([]byte, bool, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store persists sessions in Redis under cms_session: keys.
Click to show internal directories.
Click to hide internal directories.