common

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2019 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	EtcdChangeGroupMinRevisionRange = 100
)
View Source
const (
	MaxCacheKeyLength = 200
)

Variables

View Source
var (
	EtcdSchedulerBaseDir = "scheduler"

	EtcdRunsDir             = path.Join(EtcdSchedulerBaseDir, "runs")
	EtcdRunSequenceKey      = path.Join(EtcdSchedulerBaseDir, "runsequence")
	EtcdRunEventKey         = path.Join(EtcdSchedulerBaseDir, "runevents")
	EtcdRunEventSequenceKey = path.Join(EtcdSchedulerBaseDir, "runeventsequence")

	EtcdChangeGroupsDir           = path.Join(EtcdSchedulerBaseDir, "changegroups")
	EtcdChangeGroupMinRevisionKey = path.Join(EtcdSchedulerBaseDir, "changegroupsminrev")

	EtcdExecutorsDir = path.Join(EtcdSchedulerBaseDir, "executors")
	EtcdTasksDir     = path.Join(EtcdSchedulerBaseDir, "tasks")

	EtcdPingKey = path.Join(EtcdSchedulerBaseDir, "ping")

	EtcdCompactChangeGroupsLockKey = path.Join(EtcdSchedulerBaseDir, "compactchangegroupslock")
	EtcdCacheCleanerLockKey        = path.Join(EtcdSchedulerBaseDir, "locks", "cachecleaner")
	EtcdWorkspaceCleanerLockKey    = path.Join(EtcdSchedulerBaseDir, "locks", "workspacecleaner")
	EtcdTaskUpdaterLockKey         = path.Join(EtcdSchedulerBaseDir, "locks", "taskupdater")

	EtcdMaintenanceKey = "maintenance"
)
View Source
var (
	StorageDataDir        = ""
	StorageRunsDir        = path.Join(StorageDataDir, "runs")
	StorageRunsConfigDir  = path.Join(StorageDataDir, "runsconfig")
	StorageRunsIndexesDir = path.Join(StorageDataDir, "runsindexes")
	StorageCountersDir    = path.Join(StorageDataDir, "counters")
)

Functions

func EtcdExecutorKey

func EtcdExecutorKey(taskID string) string

func EtcdRunKey

func EtcdRunKey(runID string) string

func EtcdTaskKey

func EtcdTaskKey(taskID string) string

func GenExecutorTask added in v0.3.0

func GenExecutorTask(r *types.Run, rt *types.RunTask, rc *types.RunConfig, executor *types.Executor) *types.ExecutorTask

func GenExecutorTaskSpecData added in v0.3.0

func GenExecutorTaskSpecData(r *types.Run, rt *types.RunTask, rc *types.RunConfig) *types.ExecutorTaskSpecData

func NewErrNotExist

func NewErrNotExist(err error) error

func NewRunEvent

func NewRunEvent(ctx context.Context, e *etcd.Store, runID string, phase types.RunPhase, result types.RunResult) (*types.RunEvent, error)

func OSTRootGroup added in v0.3.0

func OSTRootGroup(group string) string

func OSTSubGroupTypes added in v0.3.0

func OSTSubGroupTypes(group string) []string

func OSTSubGroups added in v0.3.0

func OSTSubGroups(group string) []string

func OSTSubGroupsAndGroupTypes added in v0.3.0

func OSTSubGroupsAndGroupTypes(group string) []string

Types

type DataType

type DataType string
const (
	DataTypeRun        DataType = "run"
	DataTypeRunConfig  DataType = "runconfig"
	DataTypeRunCounter DataType = "runcounter"
)

type ErrNotExist

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

func (ErrNotExist) Error

func (e ErrNotExist) Error() string

Jump to

Keyboard shortcuts

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