Documentation ¶
Overview ¶
Package repo contains implements for app.Repo. Provide session info to and from repository.
Index ¶
- type Config
- type Repo
- func (r *Repo) ByID(ctx context.Context, sessionID uuid.UUID) (s *app.Session, err error)
- func (r *Repo) Close() error
- func (r *Repo) Delete(ctx context.Context, sessionID uuid.UUID) error
- func (r *Repo) Save(ctx context.Context, session app.Session) error
- func (r *Repo) UpdateStatus(ctx context.Context, reqID, userID uuid.UUID, status dom.UserStatus) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Cockroach connectors.CockroachDB MigrateDir string Driver string }
Config provide connection info for database.
type Repo ¶
type Repo struct {
// contains filtered or unexported fields
}
Repo provided data from and to database.
func New ¶
func New(ctx context.Context, reg *prometheus.Registry, namespace string, cfg Config) (*Repo, error)
New build and returns session db.
func (*Repo) UpdateStatus ¶
Click to show internal directories.
Click to hide internal directories.