usage

package
v0.0.0-...-90561fa Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Store

type Store interface {
	Add(ctx context.Context, workspace string, records []store.UsageRecord) error
	GetResourcesUsage(ctx context.Context, resources []string, startTime, endTime time.Time) ([]store.UsageRecord, error)
	GetUsage(ctx context.Context, startTime, endTime time.Time) ([]store.UsageRecord, error)
	GetUsageStats(ctx context.Context, startTime *time.Time) (*store.UsageStats, error)
}

func NewStore

func NewStore(db *sql.DB) (Store, error)

func NewWorkspaceStore

func NewWorkspaceStore(db *sql.DB, workspace string) (Store, error)

NewWorkspaceStore returns a Store bound to a specific workspace for read operations

Jump to

Keyboard shortcuts

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