controllers

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2020 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Success is the exit code of modeljob success
	Success = 0
	// ErrORMBLogin is the exit code of ormb login error
	ErrORMBLogin = 10000
	// ErrORMBPullModel is the exit code of ormb pull error
	ErrORMBPullModel = 10001
	// ErrORMBExportModel is the exit code of ormb export error
	ErrORMBExportModel = 10002
	// ErrRunTask is the exit code of run task error
	ErrRunTask = 10003
	// ErrORMBSaveModel is the exit code of ormb save error
	ErrORMBSaveModel = 10004
	// ErrORMBPushModel is the exit code of ormb push error
	ErrORMBPushModel = 10005
)
View Source
const (
	// ControllerName is the name of the controller.
	ControllerName = "modeljob-operator"
)

Variables

View Source
var (
	// ModelFormatToFrameworkMapping is the map for model's format to model's framework.
	ModelFormatToFrameworkMapping map[modeljobsv1alpha1.Format]modeljobsv1alpha1.Framework
	// PresetAnalyzeImageConfig is the preset image of analyze for some model's format.
	PresetAnalyzeImageConfig *corev1.ConfigMap

	// KleverModelRegistryAddressEnvKey is the address of klever-model-registry
	KleverModelRegistryAddressEnvKey = "KLEVER_MODEL_REGISTRY_ADDRESS"

	// DefaultSchedulerName is default scheduler name
	DefaultSchedulerName = "default-scheduler"

	// SchedulerNameEnvKey is the env key for scheduler name, it is set in Deployment
	SchedulerNameEnvKey = "SCHEDULER_NAME"
)

Functions

func Initialization

func Initialization() error

Types

type ModelJobReconciler

type ModelJobReconciler struct {
	client.Client
	record.EventRecorder
	Log    logr.Logger
	Scheme *runtime.Scheme
}

ModelJobReconciler reconciles a ModelJob object

func (*ModelJobReconciler) Reconcile

func (r *ModelJobReconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)

func (*ModelJobReconciler) SetupWithManager

func (r *ModelJobReconciler) SetupWithManager(mgr ctrl.Manager) error

Jump to

Keyboard shortcuts

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