Versions in this module Expand all Collapse all v0 v0.8.0 Oct 18, 2026 Changes in this version + var ErrEmptyKey = errors.New("guard: empty rule or value") + var ErrNoTenant = errors.New("guard: no tenant in context") + var ErrTaken = errors.New("guard: key already claimed") + type InMemoryStore struct + func NewInMemoryStore() *InMemoryStore + func (s *InMemoryStore) Claim(ctx context.Context, key Key) error + type Key struct + Rule string + Value string + type PgOption func(*PgStore) + func WithSchema(schema string) PgOption + type PgStore struct + func NewPgStore(pool *pgxpool.Pool, opts ...PgOption) *PgStore + func (s *PgStore) Claim(ctx context.Context, key Key) error