postgres

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2026 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Schema string

Functions

func Migrate

func Migrate(ctx context.Context, db *sql.DB) error

Types

type Repository

type Repository struct{ DB *sql.DB }

func (*Repository) CheckRuntime

func (r *Repository) CheckRuntime(ctx context.Context) error

func (*Repository) Cleanup

func (r *Repository) Cleanup(ctx context.Context, before time.Time, limit int) (int64, error)

func (*Repository) Consume

func (r *Repository) Consume(ctx context.Context, d n.Event, hash string, now time.Time, window time.Duration) (n.Result, error)

func (*Repository) List

func (r *Repository) List(ctx context.Context, owner string, c n.Cursor, limit int) ([]n.Notification, error)

func (*Repository) MarkAllRead

func (r *Repository) MarkAllRead(ctx context.Context, owner string, now time.Time) error

func (*Repository) MarkRead

func (r *Repository) MarkRead(ctx context.Context, owner, id string, now time.Time) error

func (*Repository) Preferences

func (r *Repository) Preferences(ctx context.Context, owner string, value *bool) (n.Preferences, error)

func (*Repository) Unread

func (r *Repository) Unread(ctx context.Context, owner string) (int64, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL