Documentation ¶
Index ¶
- func CheckParams(params map[string]string) error
- func CreateWorkflowExecution(ctx context.Context, mc model.ClientSet, opts CreateWorkflowExecutionOptions) (*model.WorkflowExecution, error)
- func CreateWorkflowStageExecution(ctx context.Context, mc model.ClientSet, ...) (*model.WorkflowStageExecution, error)
- func CreateWorkflowStepExecution(ctx context.Context, mc model.ClientSet, ...) (*model.WorkflowStepExecution, error)
- func EnvironmentConnectorsEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Environment) error
- func EnvironmentVariablesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Environment) error
- func ExposeResourceDefinition(_rd *model.ResourceDefinition) *model.ResourceDefinitionOutput
- func ExposeResourceDefinitions(_rds []*model.ResourceDefinition) []*model.ResourceDefinitionOutput
- func ExposeTemplateVersion(_tv *model.TemplateVersion) *model.TemplateVersionOutput
- func ExposeTemplateVersions(_tvs []*model.TemplateVersion) []*model.TemplateVersionOutput
- func GetEnvironmentByID(ctx context.Context, mc model.ClientSet, id object.ID) (*model.Environment, error)
- func GetEnvironmentsByIDs(ctx context.Context, mc model.ClientSet, ids ...object.ID) ([]*model.Environment, error)
- func GetLatestRevisions(ctx context.Context, modelClient model.ClientSet, resourceIDs ...object.ID) ([]*model.ResourceRevision, error)
- func GetResourceDependantIDs(ctx context.Context, mc model.ClientSet, resourceIDs ...object.ID) ([]object.ID, error)
- func GetResourceDependantNames(ctx context.Context, modelClient model.ClientSet, entity *model.Resource) ([]string, error)
- func GetResourceNamesByIDs(ctx context.Context, modelClient model.ClientSet, resourceIDs ...object.ID) ([]string, error)
- func ProjectSubjectRolesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Project) error
- func ResourceComponentGetUniqueKey(r *model.ResourceComponent) string
- func ResourceComponentInstancesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.ResourceComponent) error
- func ResourceComponentRelationshipUpdateWithDependencies(ctx context.Context, mc model.ClientSet, dependencies map[string][]string, ...) error
- func ResourceComponentShapeClassQuery(query *model.ResourceComponentQuery) *model.ResourceComponentQuery
- func ResourceComponentToMap(resources []*model.ResourceComponent) map[string]*model.ResourceComponent
- func ResourceDefinitionMatchingRulesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.ResourceDefinition) error
- func ResourceDependenciesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Resource) error
- func ResourceRelationshipCheckCycle(s *model.ResourceRelationship) bool
- func ResourceRelationshipGetDependencyNames(entity *model.Resource) []string
- func SubjectRolesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Subject) error
- func WorkflowStageStepsEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.WorkflowStage) error
- func WorkflowStagesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Workflow) error
- type CreateWorkflowExecutionOptions
- type CreateWorkflowStageExecutionOptions
- type CreateWorkflowStepExecutionOptions
- type ExecuteOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckParams ¶
CheckParams checks if the params contain keywords. These keywords will reconginzed as the params like "{{input.parameters.xxx}}" of argo that may cause workflow execution failure.
func CreateWorkflowExecution ¶ added in v0.4.0
func CreateWorkflowExecution( ctx context.Context, mc model.ClientSet, opts CreateWorkflowExecutionOptions, ) (*model.WorkflowExecution, error)
func CreateWorkflowStageExecution ¶ added in v0.4.0
func CreateWorkflowStageExecution( ctx context.Context, mc model.ClientSet, opts CreateWorkflowStageExecutionOptions, ) (*model.WorkflowStageExecution, error)
func CreateWorkflowStepExecution ¶ added in v0.4.0
func CreateWorkflowStepExecution( ctx context.Context, mc model.ClientSet, opts CreateWorkflowStepExecutionOptions, ) (*model.WorkflowStepExecution, error)
func EnvironmentConnectorsEdgeSave ¶
func EnvironmentConnectorsEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Environment) error
EnvironmentConnectorsEdgeSave saves the edge connectors of model.Environment entity.
func EnvironmentVariablesEdgeSave ¶ added in v0.4.0
func EnvironmentVariablesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Environment) error
EnvironmentVariablesEdgeSave saves the edge variables of model.Environment entity.
func ExposeResourceDefinition ¶ added in v0.4.0
func ExposeResourceDefinition(_rd *model.ResourceDefinition) *model.ResourceDefinitionOutput
ExposeResourceDefinition converts the ResourceDefinition to ResourceDefinitionOutput.
func ExposeResourceDefinitions ¶ added in v0.4.0
func ExposeResourceDefinitions(_rds []*model.ResourceDefinition) []*model.ResourceDefinitionOutput
ExposeResourceDefinitions converts the ResourceDefinition slice to ResourceDefinitionOutput pointer slice.
func ExposeTemplateVersion ¶ added in v0.4.0
func ExposeTemplateVersion(_tv *model.TemplateVersion) *model.TemplateVersionOutput
ExposeTemplateVersion converts the TemplateVersion to TemplateVersionOutput.
func ExposeTemplateVersions ¶ added in v0.4.0
func ExposeTemplateVersions(_tvs []*model.TemplateVersion) []*model.TemplateVersionOutput
ExposeTemplateVersions converts the TemplateVersion slice to TemplateVersionOutput pointer slice.
func GetEnvironmentByID ¶
func GetEnvironmentByID(ctx context.Context, mc model.ClientSet, id object.ID) (*model.Environment, error)
GetEnvironmentByID gets an environment including project & connectors edges by ID.
func GetEnvironmentsByIDs ¶
func GetEnvironmentsByIDs(ctx context.Context, mc model.ClientSet, ids ...object.ID) ([]*model.Environment, error)
GetEnvironmentsByIDs gets environments including project & connectors edges by IDs.
func GetLatestRevisions ¶
func GetResourceDependantIDs ¶ added in v0.4.0
func GetResourceDependantIDs(ctx context.Context, mc model.ClientSet, resourceIDs ...object.ID) ([]object.ID, error)
GetResourceDependantIDs gets IDs of resources that depend on the given resources.
func GetResourceDependantNames ¶ added in v0.4.0
func GetResourceDependantNames( ctx context.Context, modelClient model.ClientSet, entity *model.Resource, ) ([]string, error)
GetResourceDependantNames gets names of resources that depends on the given resource.
func GetResourceNamesByIDs ¶ added in v0.4.0
func ProjectSubjectRolesEdgeSave ¶
func ProjectSubjectRolesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Project) error
ProjectSubjectRolesEdgeSave saves the edge subject roles of model.Project entity.
func ResourceComponentGetUniqueKey ¶ added in v0.4.0
func ResourceComponentGetUniqueKey(r *model.ResourceComponent) string
ResourceComponentGetUniqueKey returns the unique index key of the given model.ResourceComponent.
func ResourceComponentInstancesEdgeSave ¶ added in v0.4.0
func ResourceComponentInstancesEdgeSave( ctx context.Context, mc model.ClientSet, entity *model.ResourceComponent, ) error
ResourceComponentInstancesEdgeSave saves the edge instances of model.ResourceComponent entity.
func ResourceComponentRelationshipUpdateWithDependencies ¶ added in v0.4.0
func ResourceComponentRelationshipUpdateWithDependencies( ctx context.Context, mc model.ClientSet, dependencies map[string][]string, recordResources, createResources model.ResourceComponents, ) error
ResourceComponentRelationshipUpdateWithDependencies updates the relationship with dependencies and resources.
func ResourceComponentShapeClassQuery ¶ added in v0.4.0
func ResourceComponentShapeClassQuery(query *model.ResourceComponentQuery) *model.ResourceComponentQuery
ResourceComponentShapeClassQuery wraps the given model.ResourceComponent query to select all shape class resources and the owned components and dependencies of them.
func ResourceComponentToMap ¶ added in v0.4.0
func ResourceComponentToMap(resources []*model.ResourceComponent) map[string]*model.ResourceComponent
ResourceComponentToMap recursive set a map of resource components indexed by its unique index.
func ResourceDefinitionMatchingRulesEdgeSave ¶ added in v0.4.0
func ResourceDefinitionMatchingRulesEdgeSave( ctx context.Context, mc model.ClientSet, entity *model.ResourceDefinition, ) error
ResourceDefinitionMatchingRulesEdgeSave saves the edge matching rules of model.ResourceDefinition entity.
func ResourceDependenciesEdgeSave ¶ added in v0.4.0
func ResourceDependenciesEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.Resource) error
ResourceDependenciesEdgeSave saves the edge dependencies of model.Resource entity.
func ResourceRelationshipCheckCycle ¶ added in v0.4.0
func ResourceRelationshipCheckCycle(s *model.ResourceRelationship) bool
ResourceRelationshipCheckCycle checks if the path contains a dependency cycle.
func ResourceRelationshipGetDependencyNames ¶ added in v0.4.0
ResourceRelationshipGetDependencyNames gets dependency resource names of the given resource.
func SubjectRolesEdgeSave ¶
SubjectRolesEdgeSave saves the global scope edge roles of model.Subject entity, the roles must not have project id.
func WorkflowStageStepsEdgeSave ¶ added in v0.4.0
func WorkflowStageStepsEdgeSave(ctx context.Context, mc model.ClientSet, entity *model.WorkflowStage) error
WorkflowStageStepsEdgeSave saves the edge steps of model.WorkflowStage entity.
Types ¶
type CreateWorkflowExecutionOptions ¶ added in v0.4.0
type CreateWorkflowExecutionOptions struct { ExecuteOptions `json:",inline"` Workflow *model.Workflow }
type CreateWorkflowStageExecutionOptions ¶ added in v0.4.0
type CreateWorkflowStageExecutionOptions struct { ExecuteOptions `json:",inline"` WorkflowExecution *model.WorkflowExecution Stage *model.WorkflowStage }
type CreateWorkflowStepExecutionOptions ¶ added in v0.4.0
type CreateWorkflowStepExecutionOptions struct { ExecuteOptions `json:",inline"` StageExecution *model.WorkflowStageExecution Step *model.WorkflowStep }