db

package
v0.9.219 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2024 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SQLITE_DB_PATH = "/tmp/sqlite_cedana.db"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DB

type DB interface {
	// Getters
	GetJob(context.Context, []byte) (models.Job, error)

	// Setters (create or update)
	PutJob(context.Context, []byte, []byte) error

	// Listers
	ListJobs(context.Context) ([]models.Job, error)
}

func NewLocalDB

func NewLocalDB(ctx context.Context) DB

type LocalDB

type LocalDB struct {
	// contains filtered or unexported fields
}

func (*LocalDB) GetJob added in v0.9.201

func (db *LocalDB) GetJob(ctx context.Context, jid []byte) (models.Job, error)

func (*LocalDB) ListJobs added in v0.9.201

func (db *LocalDB) ListJobs(ctx context.Context) ([]models.Job, error)

func (*LocalDB) PutJob added in v0.9.201

func (db *LocalDB) PutJob(ctx context.Context, jid []byte, state []byte) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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