arenaclient

package
v0.9.15 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2024 License: Apache-2.0 Imports: 28 Imported by: 13

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AnalyzeClient added in v0.9.14

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

func NewAnalyzeClient added in v0.9.14

func NewAnalyzeClient(namespace string, configer *config.ArenaConfiger) *AnalyzeClient

func (*AnalyzeClient) Delete added in v0.9.14

func (m *AnalyzeClient) Delete(jobType types.ModelJobType, jobNames ...string) error

func (*AnalyzeClient) Get added in v0.9.14

func (m *AnalyzeClient) Get(jobType types.ModelJobType, name string) (*types.ModelJobInfo, error)

func (*AnalyzeClient) GetAndPrint added in v0.9.14

func (m *AnalyzeClient) GetAndPrint(jobType types.ModelJobType, name string, format string) error

func (*AnalyzeClient) List added in v0.9.14

func (m *AnalyzeClient) List(allNamespaces bool, jobType types.ModelJobType) ([]*types.ModelJobInfo, error)

func (*AnalyzeClient) ListAndPrint added in v0.9.14

func (m *AnalyzeClient) ListAndPrint(allNamespaces bool, jobType types.ModelJobType, format string) error

func (*AnalyzeClient) Namespace added in v0.9.14

func (m *AnalyzeClient) Namespace(namespace string) *AnalyzeClient

Namespace sets the namespace,this operation does not change the default namespace

func (*AnalyzeClient) Submit added in v0.9.14

func (m *AnalyzeClient) Submit(job *apisanalyze.Job) error

type ArenaClient

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

ArenaClient is a client which includes operations: 1.manage training jobs,like:

  • submit a training job
  • get a training job information
  • get job logs
  • delete a job

TODO: 2.manage serving job TODO: 3.manage node it serves for commands and apis

func NewArenaClient

func NewArenaClient(args types.ArenaClientArgs) (*ArenaClient, error)

NewArenaClient creates a ArenaClient

func (*ArenaClient) Analyze added in v0.9.14

func (a *ArenaClient) Analyze() *AnalyzeClient

func (*ArenaClient) Cron added in v0.8.2

func (a *ArenaClient) Cron() *CronClient

Serving returns the Cron client

func (*ArenaClient) Data

func (a *ArenaClient) Data() *DataClient

func (*ArenaClient) Evaluate added in v0.8.8

func (a *ArenaClient) Evaluate() *EvaluateClient

func (*ArenaClient) Model added in v0.9.0

func (a *ArenaClient) Model() (*ModelClient, error)

func (*ArenaClient) Node

func (a *ArenaClient) Node() *NodeClient

func (*ArenaClient) Serving

func (a *ArenaClient) Serving() *ServingJobClient

Serving returns the Serving job client

func (*ArenaClient) Training

func (a *ArenaClient) Training() *TrainingJobClient

Training returns the Training Job Client

type CronClient added in v0.8.2

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

func NewCronClient added in v0.8.2

func NewCronClient(namespace string, configer *config.ArenaConfiger) *CronClient

NewCronClient creates a CronClient

func (*CronClient) Delete added in v0.8.2

func (c *CronClient) Delete(names ...string) error

func (*CronClient) Get added in v0.8.2

func (c *CronClient) Get(name string) (*types.CronInfo, error)

func (*CronClient) GetAndPrint added in v0.8.2

func (c *CronClient) GetAndPrint(name string, format string) error

func (*CronClient) List added in v0.8.2

func (c *CronClient) List(allNamespaces bool) ([]*types.CronInfo, error)

List return all cron task

func (*CronClient) ListAndPrint added in v0.8.2

func (c *CronClient) ListAndPrint(allNamespaces bool, format string) error

ListAndPrint lists and prints the job informations

func (*CronClient) Namespace added in v0.8.2

func (c *CronClient) Namespace(namespace string) *CronClient

Namespace sets the namespace,this operation does not change the default namespace

func (*CronClient) Resume added in v0.8.2

func (c *CronClient) Resume(name string) error

func (*CronClient) SubmitCronTrainingJob added in v0.8.2

func (c *CronClient) SubmitCronTrainingJob(job *apiscron.Job) error

Submit submits a training job

func (*CronClient) Suspend added in v0.8.2

func (c *CronClient) Suspend(name string) error

type DataClient

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

func NewDataClient

func NewDataClient(namespace string, configer *config.ArenaConfiger) *DataClient

NewDataClient creates a ServingJobClient

func (*DataClient) ListAndPrintDataVolumes

func (d *DataClient) ListAndPrintDataVolumes(namespace string, allNamespaces bool) error

func (*DataClient) Namespace

func (d *DataClient) Namespace(namespace string) *DataClient

Namespace sets the namespace,this operation does not change the default namespace

type EvaluateClient added in v0.8.8

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

func NewEvaluateClient added in v0.8.8

func NewEvaluateClient(namespace string, configer *config.ArenaConfiger) *EvaluateClient

NewEvaluateClient creates a EvaluateClient

func (*EvaluateClient) Delete added in v0.8.8

func (c *EvaluateClient) Delete(names ...string) error

func (*EvaluateClient) Get added in v0.8.8

func (c *EvaluateClient) Get(name, namespace string) (*types.EvaluateJobInfo, error)

func (*EvaluateClient) GetAndPrint added in v0.8.8

func (c *EvaluateClient) GetAndPrint(name string, format string) error

func (*EvaluateClient) List added in v0.8.8

func (c *EvaluateClient) List(allNamespaces bool) ([]*types.EvaluateJobInfo, error)

func (*EvaluateClient) ListAndPrint added in v0.8.8

func (c *EvaluateClient) ListAndPrint(allNamespaces bool, format string) error

func (*EvaluateClient) Namespace added in v0.8.8

func (c *EvaluateClient) Namespace(namespace string) *EvaluateClient

Namespace sets the namespace,this operation does not change the default namespace

func (*EvaluateClient) SubmitEvaluateJob added in v0.8.8

func (c *EvaluateClient) SubmitEvaluateJob(job *apievaluate.EvaluateJob) error

SubmitEvaluateJob submits a evaluate job

type ModelClient added in v0.9.0

type ModelClient struct {
	model.MlflowClient
	// contains filtered or unexported fields
}

func NewModelClient added in v0.9.0

func NewModelClient(namespace string, configer *config.ArenaConfiger) (*ModelClient, error)

type NodeClient

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

func NewNodeClient

func NewNodeClient(namespace string, configer *config.ArenaConfiger) *NodeClient

NewNodeClient creates a ServingJobClient

func (*NodeClient) Details

func (t *NodeClient) Details(nodeNames []string, nodeType types.NodeType, showMetric bool) (types.AllNodeInfo, error)

Details is used to serve api

func (*NodeClient) ListAndPrintNodes

func (t *NodeClient) ListAndPrintNodes(nodeNames []string, nodeType types.NodeType, format types.FormatStyle, details bool, notStop bool, showMetric bool) error

ListAndPrintNodes is used to display nodes informations

func (*NodeClient) Namespace

func (t *NodeClient) Namespace(namespace string) *NodeClient

Namespace sets the namespace,this operation does not change the default namespace

type ServingJobClient

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

ServingJobClient provides some operators for managing serving jobs.

func NewServingJobClient

func NewServingJobClient(namespace string, configer *config.ArenaConfiger) *ServingJobClient

NewServingJobClient creates a ServingJobClient

func (*ServingJobClient) Attach added in v0.8.0

func (t *ServingJobClient) Attach(jobName, version string, jobType types.ServingJobType, args *podexec.AttachPodArgs) error

func (*ServingJobClient) Delete

func (t *ServingJobClient) Delete(jobType types.ServingJobType, version string, jobNames ...string) error

Delete deletes the target serving job

func (*ServingJobClient) Get

func (t *ServingJobClient) Get(jobName, version string, jobType types.ServingJobType) (*types.ServingJobInfo, error)

Get returns a serving job information

func (*ServingJobClient) GetAndPrint

func (t *ServingJobClient) GetAndPrint(jobName, version string, jobType types.ServingJobType, format string) error

GetAndPrint print serving job information

func (*ServingJobClient) List

func (t *ServingJobClient) List(allNamespaces bool, servingType types.ServingJobType) ([]*types.ServingJobInfo, error)

List returns all serving jobs

func (*ServingJobClient) ListAndPrint

func (t *ServingJobClient) ListAndPrint(allNamespaces bool, servingType types.ServingJobType, format string) error

ListAndPrint lists and prints the job informations

func (*ServingJobClient) Logs

func (t *ServingJobClient) Logs(jobName, version string, jobType types.ServingJobType, args *types.LogArgs) error

Logs returns the serving job log

func (*ServingJobClient) Namespace

func (t *ServingJobClient) Namespace(namespace string) *ServingJobClient

Namespace sets the namespace,this operation does not change the default namespace

func (*ServingJobClient) Submit

func (t *ServingJobClient) Submit(job *apiserving.Job) error

Submit submits a serving job

func (*ServingJobClient) TrafficRouterSplit

func (t *ServingJobClient) TrafficRouterSplit(args *types.TrafficRouterSplitArgs) error

func (*ServingJobClient) Update added in v0.8.9

func (t *ServingJobClient) Update(job *apiserving.Job) error

Update update a serving job

type TrainingJobClient

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

TrainingJobClient provides some operators for managing training jobs.

func NewTrainingJobClient

func NewTrainingJobClient(namespace, arenaSystemNamespace string, configer *config.ArenaConfiger) *TrainingJobClient

NewTrainingJobClient creates a TrainingJobClient

func (*TrainingJobClient) Attach added in v0.8.0

func (t *TrainingJobClient) Attach(jobName string, jobType types.TrainingJobType, args *podexec.AttachPodArgs) error

func (*TrainingJobClient) Delete

func (t *TrainingJobClient) Delete(jobType types.TrainingJobType, jobNames ...string) error

Delete deletes the target training job

func (*TrainingJobClient) Get

func (t *TrainingJobClient) Get(jobName string, jobType types.TrainingJobType, showPrometheusMetric bool) (*types.TrainingJobInfo, error)

Get returns a training job information

func (*TrainingJobClient) GetAndPrint

func (t *TrainingJobClient) GetAndPrint(jobName string, jobType types.TrainingJobType, format string, showEvent bool, showGPU bool) error

GetAndPrint print training job information

func (*TrainingJobClient) List

func (t *TrainingJobClient) List(allNamespaces bool, trainingType types.TrainingJobType, showPrometheusMetric bool) ([]*types.TrainingJobInfo, error)

List returns all training jobs

func (*TrainingJobClient) ListAndPrint

func (t *TrainingJobClient) ListAndPrint(allNamespaces bool, format string, trainingType types.TrainingJobType) error

ListAndPrint lists and prints the job informations

func (*TrainingJobClient) LogViewer

func (t *TrainingJobClient) LogViewer(jobName string, jobType types.TrainingJobType) ([]string, error)

LogViewer returns the log viewer

func (*TrainingJobClient) Logs

func (t *TrainingJobClient) Logs(jobName string, jobType types.TrainingJobType, args *types.LogArgs) error

Logs returns the training job log

func (*TrainingJobClient) Namespace

func (t *TrainingJobClient) Namespace(namespace string) *TrainingJobClient

Namespace sets the namespace

func (*TrainingJobClient) Prune

func (t *TrainingJobClient) Prune(allNamespaces bool, since time.Duration) error

Prune cleans the not running training jobs

func (*TrainingJobClient) ScaleIn

func (t *TrainingJobClient) ScaleIn(job *apistraining.Job) error

ScaleIn scales in job

func (*TrainingJobClient) ScaleOut

func (t *TrainingJobClient) ScaleOut(job *apistraining.Job) error

ScaleOut scales out job

func (*TrainingJobClient) Submit

func (t *TrainingJobClient) Submit(job *apistraining.Job) error

Submit submits a training job

func (*TrainingJobClient) Top

func (t *TrainingJobClient) Top(args []string, allNamespaces bool, jobType types.TrainingJobType, instanceName string, notStop bool, format types.FormatStyle) error

Jump to

Keyboard shortcuts

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