database

package
v0.0.22 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Database

type Database interface {
	Disconnect()

	ListInstances(ctx context.Context, limit int64, offset int64, sort string, jwt jwt.Token, asc bool, search string, includeGenerated bool) (result []model.Instance, err error)
	GetInstance(ctx context.Context, id string, jwt jwt.Token) (instance model.Instance, exists bool, err error)
	CreateInstance(ctx context.Context, instance model.Instance, jwt jwt.Token) error
	SetInstance(ctx context.Context, instance model.Instance, jwt jwt.Token) error
	RemoveInstance(ctx context.Context, id string, jwt jwt.Token) error
	CountInstances(ctx context.Context, jwt jwt.Token, search string, includeGenerated bool) (count int64, err error)
}

func New

func New(conf config.Config, perm permV2Client.Client, ctx context.Context, wg *sync.WaitGroup) (db Database, err error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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