types

package
v1.29.0-alpha.65 Latest Latest
Warning

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

Go to latest
Published: May 23, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package types xxx

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BcsKV

type BcsKV struct {
	Key   string
	Value string
}

BcsKV key/value structure for anywhere necessary

type BcsPort

type BcsPort struct {
	Name          string `json:"name,omitempty"`
	ContainerPort string `json:"containerPort,omitempty"`
	HostPort      string `json:"hostPort,omitempty"`
	Protocol      string `json:"protocol,omitempty"`
	HostIP        string `json:"hostIP,omitempty"` // use for host has multiple ip address
}

BcsPort port service for process port reflection

type BcsProcessInfo

type BcsProcessInfo struct {
	ID          string                 `json:"ID,omitempty"`          // container ID
	Name        string                 `json:"Name,omitempty"`        // container name
	Pid         int                    `json:"Pid,omitempty"`         // container pid
	StartAt     time.Time              `json:"StartAt,omitempty"`     // startting time
	FinishAt    time.Time              `json:"FinishAt,omitempty"`    // Exit time
	Status      string                 `json:"Status,omitempty"`      // status string, paused, restarting, running, dead, created, exited
	Healthy     bool                   `json:"Healthy,omitempty"`     // Container healthy
	ExitCode    int                    `json:"ExitCode,omitempty"`    // container exit code
	Hostname    string                 `json:"Hostname,omitempty"`    // container host name
	NetworkMode string                 `json:"NetworkMode,omitempty"` // Network mode for container
	IPAddress   string                 `json:"IPAddress,omitempty"`   // Contaienr IP address
	NodeAddress string                 `json:"NodeAddress,omitempty"` // node host address
	Ports       []BcsPort              `json:"Ports,omitempty"`       // ports info for report
	Message     string                 `json:"Message,omitempty"`     // status message for container
	Resource    *schedTypes.Resource   `json:"Resource,omitempty"`
	BcsMessage  *schedTypes.BcsMessage `json:",omitempty"`
}

BcsProcessInfo only for BcsExecutor

type CallbackFuncType

type CallbackFuncType string

CallbackFuncType xxx

const (
	// CallbackFuncUpdateTask xxx
	CallbackFuncUpdateTask CallbackFuncType = "UpdateTaskFunc"
)

type CheckSum

type CheckSum struct {
	Md5 string
}

CheckSum xxx

type ExecutorStatus

type ExecutorStatus string

ExecutorStatus type

const (
	// ExecutorStatusUnknown xxx
	ExecutorStatusUnknown ExecutorStatus = "unknown"
	// ExecutorStatusLaunching xxx
	ExecutorStatusLaunching ExecutorStatus = "launching"
	// ExecutorStatusRunning xxx
	ExecutorStatusRunning ExecutorStatus = "running"
	// ExecutorStatusShutdown xxx
	ExecutorStatusShutdown ExecutorStatus = "shutdown"
	// ExecutorStatusFinish xxx
	ExecutorStatusFinish ExecutorStatus = "finish"
)

type HeartBeat

type HeartBeat struct {
	ProcessId  string
	ExecutorId string
	Type       HeartBeatType
}

HeartBeat xxx executor & process daemon heartbeat mechanism

type HeartBeatType

type HeartBeatType string

HeartBeatType xxx

const (
	// HeartBeatPing xxx
	HeartBeatPing HeartBeatType = "ping"
	// HeartBeatPong xxx
	HeartBeatPong HeartBeatType = "pong"
)

type JfrogRegistry

type JfrogRegistry struct {
	DownloadUri string
	Checksums   *CheckSum
}

JfrogRegistry xxx

type LocalFile

type LocalFile struct {
	To    string
	Right string
	User  string
	Value string
}

LocalFile xxx local file

type ProcessInfo

type ProcessInfo struct {
	Id string

	// process info
	WorkDir          string // 进程工作目录
	ProcessName      string // 进程名,pid文件所对应的名称
	Uris             []*Uri // process packages uris
	PidFile          string // process pid file path
	StartCmd         string // process start command
	StartGracePeriod int64  // start process grace period seconds
	StopCmd          string // process stop command
	StopTimeout      int
	KillCmd          string // kill -9
	Resource         *bcstype.Resource
	Envs             []string // in the form "key=value".
	Argv             []string
	User             string

	// status info
	StatusInfo *ProcessStatusInfo

	// exexutor
	ExecutorId            string // process executor id
	ExecutorHeartBeatTime int64  // process daemon & process executor last heartbeat time
}

ProcessInfo xxx

type ProcessStatusInfo

type ProcessStatusInfo struct {
	Id            string
	Status        ProcessStatusType
	ExitCode      int    // '0' show finish, >'0' show failed
	Message       string // if failed,then message
	Pid           int
	RegisterTime  int64
	LastStartTime int64
}

ProcessStatusInfo xxx

type ProcessStatusType

type ProcessStatusType string

ProcessStatusType xxx

const (
	// ProcessStatusStaging xxx
	ProcessStatusStaging ProcessStatusType = "staging"
	// ProcessStatusStarting xxx
	ProcessStatusStarting ProcessStatusType = "starting"
	// ProcessStatusRunning xxx
	ProcessStatusRunning ProcessStatusType = "running"
	// ProcessStatusStopping xxx
	ProcessStatusStopping ProcessStatusType = "stopping"
	// ProcessStatusStopped xxx
	ProcessStatusStopped ProcessStatusType = "stopped"
)

type ProcessTaskInfo

type ProcessTaskInfo struct {
	TaskId     string
	LocalFiles []*LocalFile

	ProcInfo *ProcessInfo
	Status   TaskStatus
	// contains filtered or unexported fields
}

ProcessTaskInfo xxx

type TaskStatus

type TaskStatus string

TaskStatus xxx process task status type

const (
	// TaskStatusStaging xxx
	TaskStatusStaging TaskStatus = "staging"
	// TaskStatusStarting xxx
	TaskStatusStarting TaskStatus = "starting"
	// TaskStatusRunning xxx
	TaskStatusRunning TaskStatus = "running"
	// TaskStatusKilling xxx
	TaskStatusKilling TaskStatus = "killing"
	// TaskStatusFailed xxx
	TaskStatusFailed TaskStatus = "failed"
	// TaskStatusFinish xxx
	TaskStatusFinish TaskStatus = "finish"
	// TaskStatusError xxx
	TaskStatusError TaskStatus = "error"
)

type UpdateTaskFunc

type UpdateTaskFunc func(*mesos.TaskStatus) error

UpdateTaskFunc xxx

type Uri

type Uri struct {
	Value        string // process package registry uri, example for "http://xxx.artifactory.xxx.com/xxx/v1/pack.tar.gz"
	User         string // package registry user
	Pwd          string // package registry password, example for curl -u 'user:pwd' -X GET "http://xxx.artifactory.xxx.com/xxx/v1/pack.tar.gz"
	OutputDir    string
	ExtractDir   string
	PackagesFile string
}

Uri xxx

Jump to

Keyboard shortcuts

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