Documentation
¶
Overview ¶
Package readinesssvc evaluates persisted pipeline setup without running connectors.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Diagnostic ¶
type Diagnostic struct {
Severity string `json:"severity"`
Code string `json:"code"`
EnvironmentSlug slug.Slug `json:"environment_slug"`
PipelineSlug slug.Slug `json:"pipeline_slug"`
StepSlug slug.Slug `json:"step_slug"`
RequirementKey string `json:"requirement_key"`
FieldPath string `json:"field_path"`
NextAction string `json:"next_action"`
}
type EnvironmentInput ¶
type EnvironmentResult ¶
type EnvironmentResult struct {
EnvironmentSlug slug.Slug `json:"environment_slug"`
Status string `json:"status"`
Diagnostics []Diagnostic `json:"diagnostics"`
}
type PipelineInput ¶
type PipelineInput struct {
Spec *pipelinespec.Pipeline
Refs []model.DataSourceRef
Bindings []model.DataSourceBinding
}
type Report ¶
type Report struct {
Status string `json:"status"`
Environments []EnvironmentResult `json:"environments"`
}
func Evaluate ¶
func Evaluate(pipelines []PipelineInput, environments []EnvironmentInput) Report
func Load ¶
func Load(ctx context.Context, pipelines pipelinesvc.Service, environments environmentssvc.Service, refs datasourcerefssvc.Service, org, project, pipeline slug.Slug) (Report, error)
Load evaluates the current persisted specs. An empty pipeline selects the whole project.
func LoadSpecs ¶
func LoadSpecs(ctx context.Context, environments environmentssvc.Service, refs datasourcerefssvc.Service, org, project slug.Slug, specs []*pipelinespec.Pipeline) ([]Report, error)
LoadSpecs evaluates incoming pipeline specs against the project's current setup.