db

package
v0.6.0-rc.0 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2019 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 GetWorkerLogOpts

type GetWorkerLogOpts struct {
	Name       string
	SinceTime  *time.Time
	Descending bool
	Limit      int32
	Objective  bool
}

type KatibDBInterface

type KatibDBInterface interface {
	DBInit()
	SelectOne() error

	RegisterExperiment(experiment *v1alpha2.Experiment) error
	PreCheckRegisterExperiment(experiment *v1alpha2.Experiment) (bool, error)
	DeleteExperiment(experimentName string) error
	GetExperiment(experimentName string) (*v1alpha2.Experiment, error)
	GetExperimentList() ([]*v1alpha2.ExperimentSummary, error)
	UpdateExperimentStatus(experimentName string, newStatus *v1alpha2.ExperimentStatus) error

	UpdateAlgorithmExtraSettings(experimentName string, extraAlgorithmSetting []*v1alpha2.AlgorithmSetting) error
	GetAlgorithmExtraSettings(experimentName string) ([]*v1alpha2.AlgorithmSetting, error)

	RegisterTrial(trial *v1alpha2.Trial) error
	GetTrialList(experimentName string, filter string) ([]*v1alpha2.Trial, error)
	GetTrial(trialName string) (*v1alpha2.Trial, error)
	UpdateTrialStatus(trialName string, newStatus *v1alpha2.TrialStatus) error
	DeleteTrial(trialName string) error

	RegisterObservationLog(trialName string, observationLog *v1alpha2.ObservationLog) error
	GetObservationLog(trialName string, metricName string, startTime string, endTime string) (*v1alpha2.ObservationLog, error)
}

func New

func New() (KatibDBInterface, error)

func NewWithSQLConn

func NewWithSQLConn(db *sql.DB) (KatibDBInterface, error)

type WorkerLog

type WorkerLog struct {
	Time  time.Time
	Name  string
	Value string
}

Jump to

Keyboard shortcuts

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