v1

package
v0.0.1-beta Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CompanyMetadata

type CompanyMetadata struct {
	Labels                    map[string]string `bson:"labels" json:"labels" yaml:"labels"`
	NumberOfConcurrentProcess int64             `bson:"number_of_concurrent_process" json:"number_of_concurrent_process" yaml:"number_of_concurrent_process"`
	TotalProcessPerDay        int64             `bson:"total_process_per_day" json:"total_process_per_day" yaml:"total_process_per_day"`
}

CompanyMetadata company metadata

type DeployableResource

type DeployableResource struct {
	Step           string                       `json:"step" bson:"step" yaml:"step"`
	ProcessId      string                       `json:"process_id" bson:"process_id" yaml:"process_id"`
	Descriptors    *[]unstructured.Unstructured `json:"descriptors" yaml:"descriptors" bson:"descriptors"`
	Type           enums.PIPELINE_RESOURCE_TYPE `json:"type" bson:"type" yaml:"type"`
	Name           string                       `json:"name" bson:"name" yaml:"name"`
	Namespace      string                       `json:"namespace" bson:"namespace" yaml:"namespace"`
	Images         []string                     `json:"images" bson:"images" yaml:"images"`
	Pipeline       *Pipeline                    `bson:"pipeline" json:"pipeline" yaml:"pipeline"`
	Claim          int                          `bson:"claim" json:"claim" yaml:"claim"`
	RolloutRestart bool                         `bson:"rollout_restart" json:"rollout_restart" yaml:"rollout_restart"`
}

DeployableResource agent applicable workload info.

type Jwt

type Jwt struct {
	PublicKey *rsa.PublicKey
}

Jwt Struct of Jwt keys

type LogEvent

type LogEvent struct {
	ProcessId string    `bson:"process_id"`
	Log       string    `bson:"log"`
	Step      string    `bson:"step"`
	Footmark  string    `bson:"footmark"`
	CreatedAt time.Time `bson:"created_at"`
	Claim     int       `bson:"claim" json:"claim"`
}

LogEvent LogEvent struct

type LogEventQueryOption

type LogEventQueryOption struct {
	Pagination struct {
		Page  int64
		Limit int64
	}
	Step string
}

LogEventQueryOption log event query params

type Pipeline

type Pipeline struct {
	MetaData   PipelineMetadata    `json:"_metadata" yaml:"_metadata"`
	Option     PipelineApplyOption `json:"option" yaml:"option"`
	ApiVersion string              `json:"api_version" yaml:"api_version"`
	Name       string              `json:"name"  yaml:"name"`
	ProcessId  string              `json:"process_id" yaml:"process_id"`
	Label      map[string]string   `json:"label" yaml:"label"`
	Steps      []Step              `json:"steps" yaml:"steps"`
	Claim      int                 `json:"claim" yaml:"claim"`
}

Pipeline Pipeline struct

func (Pipeline) Validate

func (pipeline Pipeline) Validate() error

Validate validates pipeline.

type PipelineApplyOption

type PipelineApplyOption struct {
	Purging enums.PIPELINE_PURGING
}

PipelineApplyOption pipeline apply options

type PipelineMetadata

type PipelineMetadata struct {
	CompanyId       string          `json:"company_id" yaml:"company_id"`
	CompanyMetadata CompanyMetadata `json:"company_metadata" yaml:"company_metadata"`
}

PipelineMetadata pipeline metadata

type PipelineProcessEvent

type PipelineProcessEvent struct {
	Id        string `bson:"id" json:"id"`
	ProcessId string `bson:"process_id" json:"process_id"`
	CompanyId string `bson:"company_id" json:"company_id"`
	//	Read      bool                   `bson:"read" json:"read"`
	ReadBy    []string               `bson:"read_by" json:"read_by"`
	Data      map[string]interface{} `bson:"data" json:"data"`
	CreatedAt time.Time              `bson:"created_at"`
}

PipelineProcessEvent Pipeline ProcessEvent struct

type PipelineStatusCount

type PipelineStatusCount struct {
	Pipeline struct {
		Completed      int64 `json:"completed"`
		Failed         int64 `json:"failed"`
		Running        int64 `json:"running"`
		Paused         int64 `json:"paused"`
		NonInitialized int64 `json:"nonInitialized"`
	} `json:"pipeline"`
}

PipelineStatusCount pipeline status count info

type Process

type Process struct {
	ProcessId    string                 `bson:"process_id" json:"process_id"`
	CompanyId    string                 `bson:"company_id" json:"company_id"`
	AppId        string                 `bson:"app_id" json:"app_id"`
	RepositoryId string                 `bson:"repository_id" json:"repository_id"`
	CommitId     string                 `bson:"commit_id" json:"commit_id"`
	Data         map[string]interface{} `bson:"data" json:"data"`
	CreatedAt    time.Time              `bson:"created_at" json:"created_at"`
	Branch       string                 `bson:"branch" json:"branch"`
}

Process Process struct

type ProcessFootmark

type ProcessFootmark struct {
	ProcessId string    `bson:"process_id"`
	Step      string    `bson:"step"`
	Footmark  string    `bson:"footmark"`
	Claim     int       `bson:"claim" json:"claim"`
	Time      time.Time `bson:"time" json:"time"`
}

ProcessFootmark ProcessFootmark struct

func (ProcessFootmark) GetFootMarks

func (ProcessFootmark) GetFootMarks(footmarks []ProcessFootmark) []string

type ProcessLifeCycleEvent

type ProcessLifeCycleEvent struct {
	ProcessId string               `bson:"process_id" json:"process_id"`
	Step      string               `bson:"step" json:"step"`
	StepType  enums.STEP_TYPE      `bson:"step_type" json:"step_type"`
	Status    enums.PROCESS_STATUS `bson:"status" json:"status"`
	Next      []string             `bson:"next" json:"next"`
	Agent     string               `bson:"agent" json:"agent"`
	Pipeline  *Pipeline            `bson:"pipeline" json:"pipeline"`
	CreatedAt time.Time            `bson:"created_at" json:"created_at"`
	UpdatedAt time.Time            `bson:"updated_at" json:"updated_at"`
	Trigger   enums.TRIGGER        `bson:"trigger" json:"trigger"`
	Claim     int                  `bson:"claim" json:"claim"`
	ClaimedAt time.Time            `bson:"claimed_at" json:"claimed_at"`
}

ProcessLifeCycleEvent Pipeline ProcessLifeCycleEvent struct

type ProcessLifeCycleEventList

type ProcessLifeCycleEventList struct {
	Events []ProcessLifeCycleEvent `bson:"events" json:"events" yaml:"events"`
}

ProcessLifeCycleEventList process life cycle event list

type ProcessQueryOption

type ProcessQueryOption struct {
	Pagination struct {
		Page  int64
		Limit int64
	}
	Step string
}

ProcessQueryOption process query params

type Step

type Step struct {
	Name        string                       `json:"name" yaml:"name"`
	Type        enums.STEP_TYPE              `json:"type" yaml:"type"`
	Status      enums.PROCESS_STATUS         `json:"status" yaml:"status"`
	Trigger     enums.TRIGGER                `json:"trigger" yaml:"trigger"`
	Params      map[enums.PARAMS]string      `json:"params" yaml:"params"`
	Next        []string                     `json:"next" yaml:"next"`
	ArgData     map[string]string            `json:"arg_data"  yaml:"arg_data"`
	EnvData     map[string]string            `json:"env_data"  yaml:"env_data"`
	Descriptors *[]unstructured.Unstructured `json:"descriptors,omitempty" yaml:"descriptors,omitempty"`
}

Step pipeline step.

func (Step) Validate

func (step Step) Validate() error

Validate validates pipeline steps.

type Subject

type Subject struct {
	Step, Log    string
	EventData    map[string]interface{}
	ProcessLabel map[string]string
	ProcessId    string
}

Subject subject that observers listen

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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