Documentation ¶
Index ¶
- Constants
- type AlertSpec
- type Asset
- type Change
- type ChangeLog
- type Config
- type DeployState
- type Downstream
- type DownstreamList
- type FullName
- type FullNames
- type Hook
- type Job
- func (j *Job) Destination() resource.URN
- func (j *Job) FullName() string
- func (j *Job) GetJobWithUnresolvedUpstream() (*WithUpstream, error)
- func (j *Job) GetName() string
- func (j *Job) GetStaticUpstreamsToResolve() ([]*Upstream, error)
- func (j *Job) IsDirty() bool
- func (j *Job) ProjectName() tenant.ProjectName
- func (j *Job) SetDirty(val bool)
- func (j *Job) Sources() []resource.URN
- func (j *Job) Spec() *Spec
- func (j *Job) StaticUpstreamNames() []SpecUpstreamName
- func (j *Job) Tenant() tenant.Tenant
- type Jobs
- func (j Jobs) Deduplicate() []*Job
- func (j Jobs) GetFullNameToSpecMap() map[FullName]*Spec
- func (j Jobs) GetJobNames() []Name
- func (j Jobs) GetJobsWithUnresolvedStaticUpstreams() ([]*WithUpstream, error)
- func (j Jobs) GetJobsWithUnresolvedUpstreams() ([]*WithUpstream, error)
- func (j Jobs) GetNameMap() map[Name]*Job
- func (j Jobs) GetNamespaceNameAndJobsMap() map[tenant.NamespaceName][]*Job
- func (j Jobs) GetSpecs() []*Spec
- type Metadata
- type MetadataBuilder
- type MetadataResource
- type MetadataResourceConfig
- type Name
- type ResourceURN
- type ResourceURNWithUpstreams
- type ResourceURNWithUpstreamsList
- type Retry
- type Schedule
- type ScheduleBuilder
- func (s *ScheduleBuilder) Build() (*Schedule, error)
- func (s *ScheduleBuilder) WithCatchUp(catchUp bool) *ScheduleBuilder
- func (s *ScheduleBuilder) WithDependsOnPast(dependsOnPast bool) *ScheduleBuilder
- func (s *ScheduleBuilder) WithEndDate(endDate ScheduleDate) *ScheduleBuilder
- func (s *ScheduleBuilder) WithInterval(interval string) *ScheduleBuilder
- func (s *ScheduleBuilder) WithRetry(retry *Retry) *ScheduleBuilder
- type ScheduleDate
- type Spec
- func (s *Spec) AlertSpecs() []*AlertSpec
- func (s *Spec) Asset() Asset
- func (s *Spec) Description() string
- func (s *Spec) DiffBehaviorally(incoming *Spec) bool
- func (s *Spec) Hooks() []*Hook
- func (s *Spec) Labels() labels.Labels
- func (s *Spec) Metadata() *Metadata
- func (s *Spec) Name() Name
- func (s *Spec) Owner() string
- func (s *Spec) Schedule() *Schedule
- func (s *Spec) Task() Task
- func (s *Spec) UpstreamSpec() *UpstreamSpec
- func (s *Spec) Version() int
- func (s *Spec) WebhookSpecs() []*WebhookSpec
- func (s *Spec) WindowConfig() window.Config
- type SpecBuilder
- func (s *SpecBuilder) Build() (*Spec, error)
- func (s *SpecBuilder) WithAlerts(alerts []*AlertSpec) *SpecBuilder
- func (s *SpecBuilder) WithAsset(asset Asset) *SpecBuilder
- func (s *SpecBuilder) WithDescription(description string) *SpecBuilder
- func (s *SpecBuilder) WithHooks(hooks []*Hook) *SpecBuilder
- func (s *SpecBuilder) WithLabels(labels labels.Labels) *SpecBuilder
- func (s *SpecBuilder) WithMetadata(metadata *Metadata) *SpecBuilder
- func (s *SpecBuilder) WithSpecUpstream(specUpstream *UpstreamSpec) *SpecBuilder
- func (s *SpecBuilder) WithWebhooks(webhook []*WebhookSpec) *SpecBuilder
- type SpecHTTPUpstream
- type SpecHTTPUpstreamBuilder
- type SpecUpstreamBuilder
- type SpecUpstreamName
- type Specs
- type State
- type Task
- type TaskName
- type UpdateImpact
- type Upstream
- func (u *Upstream) External() bool
- func (u *Upstream) FullName() string
- func (u *Upstream) Host() string
- func (u *Upstream) Name() Name
- func (u *Upstream) NamespaceName() tenant.NamespaceName
- func (u *Upstream) ProjectName() tenant.ProjectName
- func (u *Upstream) Resource() resource.URN
- func (u *Upstream) State() UpstreamState
- func (u *Upstream) TaskName() TaskName
- func (u *Upstream) Type() UpstreamType
- type UpstreamSpec
- type UpstreamState
- type UpstreamType
- type Upstreams
- type WebhookEndPoint
- type WebhookSpec
- type WithUpstream
- type WithUpstreams
Constants ¶
View Source
const ( EntityJob = "job" EntityJobChangeLog = "job_change_log" UpstreamTypeStatic UpstreamType = "static" UpstreamTypeInferred UpstreamType = "inferred" UpstreamStateResolved UpstreamState = "resolved" UpstreamStateUnresolved UpstreamState = "unresolved" MetricJobEvent = "job_events_total" MetricJobEventStateAdded = "added" MetricJobEventStateUpdated = "updated" MetricJobEventStateDeleted = "deleted" MetricJobEventStateUpsertFailed = "upsert_failed" MetricJobEventStateDeleteFailed = "delete_failed" MetricJobEventStateValidationFailed = "validation_failed" MetricJobEventEnabled = "enabled" MetricJobEventDisabled = "disabled" MetricJobEventFoundDirty = "found_dirty" MetricJobValidation = "job_validation" MetricJobRefreshResourceDownstream = "refresh_resource_downstream_total" UnspecifiedImpactChange UpdateImpact = "unspecified_impact" JobInternalImpact UpdateImpact = "internal_impact" JobBehaviourImpact UpdateImpact = "behaviour_impact" DeployStateSuccess DeployState = "success" DeployStateSkipped DeployState = "skipped" DeployStateFailed DeployState = "failed" )
View Source
const (
DateLayout = "2006-01-02"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AlertSpec ¶
type AlertSpec struct {
// contains filtered or unexported fields
}
func NewAlertSpec ¶
type DeployState ¶ added in v0.14.0
type DeployState string
func (DeployState) String ¶ added in v0.14.0
func (d DeployState) String() string
type Downstream ¶
type Downstream struct {
// contains filtered or unexported fields
}
func NewDownstream ¶
func NewDownstream(name Name, projectName tenant.ProjectName, namespaceName tenant.NamespaceName, taskName TaskName) *Downstream
func (Downstream) FullName ¶
func (d Downstream) FullName() FullName
func (Downstream) Name ¶
func (d Downstream) Name() Name
func (Downstream) NamespaceName ¶
func (d Downstream) NamespaceName() tenant.NamespaceName
func (Downstream) ProjectName ¶
func (d Downstream) ProjectName() tenant.ProjectName
func (Downstream) TaskName ¶
func (d Downstream) TaskName() TaskName
type DownstreamList ¶
type DownstreamList []*Downstream
func (DownstreamList) GetDownstreamFullNames ¶
func (d DownstreamList) GetDownstreamFullNames() FullNames
type FullName ¶
type FullName string
func FullNameFrom ¶
func FullNameFrom(projectName tenant.ProjectName, jobName Name) FullName
type Job ¶
type Job struct {
// contains filtered or unexported fields
}
func (*Job) Destination ¶
func (*Job) GetJobWithUnresolvedUpstream ¶
func (j *Job) GetJobWithUnresolvedUpstream() (*WithUpstream, error)
func (*Job) GetStaticUpstreamsToResolve ¶ added in v0.11.0
func (*Job) ProjectName ¶
func (j *Job) ProjectName() tenant.ProjectName
func (*Job) StaticUpstreamNames ¶
func (j *Job) StaticUpstreamNames() []SpecUpstreamName
type Jobs ¶
type Jobs []*Job
func (Jobs) Deduplicate ¶ added in v0.14.3
func (Jobs) GetFullNameToSpecMap ¶ added in v0.12.0
func (Jobs) GetJobNames ¶
func (Jobs) GetJobsWithUnresolvedStaticUpstreams ¶ added in v0.11.0
func (j Jobs) GetJobsWithUnresolvedStaticUpstreams() ([]*WithUpstream, error)
func (Jobs) GetJobsWithUnresolvedUpstreams ¶
func (j Jobs) GetJobsWithUnresolvedUpstreams() ([]*WithUpstream, error)
func (Jobs) GetNameMap ¶ added in v0.11.0
func (Jobs) GetNamespaceNameAndJobsMap ¶
func (j Jobs) GetNamespaceNameAndJobsMap() map[tenant.NamespaceName][]*Job
type Metadata ¶
type Metadata struct {
// contains filtered or unexported fields
}
func (Metadata) Resource ¶
func (m Metadata) Resource() *MetadataResource
type MetadataBuilder ¶
type MetadataBuilder struct {
// contains filtered or unexported fields
}
func NewMetadataBuilder ¶
func NewMetadataBuilder() *MetadataBuilder
func (*MetadataBuilder) Build ¶
func (m *MetadataBuilder) Build() (*Metadata, error)
func (*MetadataBuilder) WithResource ¶
func (m *MetadataBuilder) WithResource(resource *MetadataResource) *MetadataBuilder
func (*MetadataBuilder) WithScheduler ¶
func (m *MetadataBuilder) WithScheduler(scheduler map[string]string) *MetadataBuilder
type MetadataResource ¶
type MetadataResource struct {
// contains filtered or unexported fields
}
func NewResourceMetadata ¶
func NewResourceMetadata(request, limit *MetadataResourceConfig) *MetadataResource
func (MetadataResource) Limit ¶
func (m MetadataResource) Limit() *MetadataResourceConfig
func (MetadataResource) Request ¶
func (m MetadataResource) Request() *MetadataResourceConfig
type MetadataResourceConfig ¶
type MetadataResourceConfig struct {
// contains filtered or unexported fields
}
func NewMetadataResourceConfig ¶
func NewMetadataResourceConfig(cpu, memory string) *MetadataResourceConfig
func (MetadataResourceConfig) CPU ¶
func (m MetadataResourceConfig) CPU() string
func (MetadataResourceConfig) Memory ¶
func (m MetadataResourceConfig) Memory() string
type ResourceURN ¶
type ResourceURN string
func (ResourceURN) String ¶
func (n ResourceURN) String() string
type ResourceURNWithUpstreams ¶ added in v0.10.1
type ResourceURNWithUpstreams struct { URN resource.URN Upstreams []*ResourceURNWithUpstreams }
type ResourceURNWithUpstreamsList ¶ added in v0.10.1
type ResourceURNWithUpstreamsList []*ResourceURNWithUpstreams
func (ResourceURNWithUpstreamsList) Flatten ¶ added in v0.10.1
func (rs ResourceURNWithUpstreamsList) Flatten() []*ResourceURNWithUpstreams
type Retry ¶
type Retry struct {
// contains filtered or unexported fields
}
func (Retry) DelayInSeconds ¶ added in v0.12.0
func (Retry) ExponentialBackoff ¶
type Schedule ¶
type Schedule struct {
// contains filtered or unexported fields
}
func (Schedule) DependsOnPast ¶
func (Schedule) EndDate ¶
func (s Schedule) EndDate() ScheduleDate
func (Schedule) StartDate ¶
func (s Schedule) StartDate() ScheduleDate
type ScheduleBuilder ¶
type ScheduleBuilder struct {
// contains filtered or unexported fields
}
func NewScheduleBuilder ¶
func NewScheduleBuilder(startDate ScheduleDate) *ScheduleBuilder
TODO: move interval to optional
func (*ScheduleBuilder) Build ¶
func (s *ScheduleBuilder) Build() (*Schedule, error)
func (*ScheduleBuilder) WithCatchUp ¶
func (s *ScheduleBuilder) WithCatchUp(catchUp bool) *ScheduleBuilder
func (*ScheduleBuilder) WithDependsOnPast ¶
func (s *ScheduleBuilder) WithDependsOnPast(dependsOnPast bool) *ScheduleBuilder
func (*ScheduleBuilder) WithEndDate ¶
func (s *ScheduleBuilder) WithEndDate(endDate ScheduleDate) *ScheduleBuilder
func (*ScheduleBuilder) WithInterval ¶
func (s *ScheduleBuilder) WithInterval(interval string) *ScheduleBuilder
func (*ScheduleBuilder) WithRetry ¶
func (s *ScheduleBuilder) WithRetry(retry *Retry) *ScheduleBuilder
type ScheduleDate ¶
type ScheduleDate string
func ScheduleDateFrom ¶
func ScheduleDateFrom(date string) (ScheduleDate, error)
func (ScheduleDate) String ¶
func (s ScheduleDate) String() string
type Spec ¶
type Spec struct {
// contains filtered or unexported fields
}
func (*Spec) AlertSpecs ¶
func (*Spec) Description ¶
func (*Spec) DiffBehaviorally ¶ added in v0.12.0
func (*Spec) UpstreamSpec ¶
func (s *Spec) UpstreamSpec() *UpstreamSpec
func (*Spec) WebhookSpecs ¶ added in v0.11.4
func (s *Spec) WebhookSpecs() []*WebhookSpec
func (*Spec) WindowConfig ¶ added in v0.10.0
type SpecBuilder ¶
type SpecBuilder struct {
// contains filtered or unexported fields
}
func NewSpecBuilder ¶
func (*SpecBuilder) Build ¶
func (s *SpecBuilder) Build() (*Spec, error)
func (*SpecBuilder) WithAlerts ¶
func (s *SpecBuilder) WithAlerts(alerts []*AlertSpec) *SpecBuilder
func (*SpecBuilder) WithAsset ¶
func (s *SpecBuilder) WithAsset(asset Asset) *SpecBuilder
func (*SpecBuilder) WithDescription ¶
func (s *SpecBuilder) WithDescription(description string) *SpecBuilder
func (*SpecBuilder) WithHooks ¶
func (s *SpecBuilder) WithHooks(hooks []*Hook) *SpecBuilder
func (*SpecBuilder) WithLabels ¶
func (s *SpecBuilder) WithLabels(labels labels.Labels) *SpecBuilder
func (*SpecBuilder) WithMetadata ¶
func (s *SpecBuilder) WithMetadata(metadata *Metadata) *SpecBuilder
func (*SpecBuilder) WithSpecUpstream ¶
func (s *SpecBuilder) WithSpecUpstream(specUpstream *UpstreamSpec) *SpecBuilder
func (*SpecBuilder) WithWebhooks ¶ added in v0.11.4
func (s *SpecBuilder) WithWebhooks(webhook []*WebhookSpec) *SpecBuilder
type SpecHTTPUpstream ¶
type SpecHTTPUpstream struct {
// contains filtered or unexported fields
}
TODO: reconsider whether we still need it or not
func (SpecHTTPUpstream) Headers ¶
func (s SpecHTTPUpstream) Headers() map[string]string
func (SpecHTTPUpstream) Name ¶
func (s SpecHTTPUpstream) Name() string
func (SpecHTTPUpstream) Params ¶
func (s SpecHTTPUpstream) Params() map[string]string
func (SpecHTTPUpstream) URL ¶
func (s SpecHTTPUpstream) URL() string
type SpecHTTPUpstreamBuilder ¶
type SpecHTTPUpstreamBuilder struct {
// contains filtered or unexported fields
}
func NewSpecHTTPUpstreamBuilder ¶
func NewSpecHTTPUpstreamBuilder(name, url string) *SpecHTTPUpstreamBuilder
func (*SpecHTTPUpstreamBuilder) Build ¶
func (s *SpecHTTPUpstreamBuilder) Build() (*SpecHTTPUpstream, error)
func (*SpecHTTPUpstreamBuilder) WithHeaders ¶
func (s *SpecHTTPUpstreamBuilder) WithHeaders(headers map[string]string) *SpecHTTPUpstreamBuilder
func (*SpecHTTPUpstreamBuilder) WithParams ¶
func (s *SpecHTTPUpstreamBuilder) WithParams(params map[string]string) *SpecHTTPUpstreamBuilder
type SpecUpstreamBuilder ¶
type SpecUpstreamBuilder struct {
// contains filtered or unexported fields
}
func NewSpecUpstreamBuilder ¶
func NewSpecUpstreamBuilder() *SpecUpstreamBuilder
func (*SpecUpstreamBuilder) Build ¶
func (s *SpecUpstreamBuilder) Build() (*UpstreamSpec, error)
func (*SpecUpstreamBuilder) WithSpecHTTPUpstream ¶
func (s *SpecUpstreamBuilder) WithSpecHTTPUpstream(httpUpstreams []*SpecHTTPUpstream) *SpecUpstreamBuilder
func (*SpecUpstreamBuilder) WithUpstreamNames ¶
func (s *SpecUpstreamBuilder) WithUpstreamNames(names []SpecUpstreamName) *SpecUpstreamBuilder
type SpecUpstreamName ¶
type SpecUpstreamName string
func SpecUpstreamNameFrom ¶
func SpecUpstreamNameFrom(specUpstreamName string) SpecUpstreamName
func (SpecUpstreamName) GetJobName ¶
func (s SpecUpstreamName) GetJobName() (Name, error)
func (SpecUpstreamName) GetProjectName ¶
func (s SpecUpstreamName) GetProjectName() (tenant.ProjectName, error)
func (SpecUpstreamName) IsWithProjectName ¶
func (s SpecUpstreamName) IsWithProjectName() bool
func (SpecUpstreamName) String ¶
func (s SpecUpstreamName) String() string
type Specs ¶
type Specs []*Spec
func (Specs) ToFullNameAndSpecMap ¶ added in v0.7.0
func (s Specs) ToFullNameAndSpecMap(projectName tenant.ProjectName) map[FullName]*Spec
func (Specs) ToNameAndSpecMap ¶
type UpdateImpact ¶ added in v0.12.0
type UpdateImpact string
func (UpdateImpact) String ¶ added in v0.12.0
func (u UpdateImpact) String() string
type Upstream ¶
type Upstream struct {
// contains filtered or unexported fields
}
func NewUpstreamResolved ¶
func NewUpstreamUnresolvedStatic ¶
func NewUpstreamUnresolvedStatic(name Name, projectName tenant.ProjectName) *Upstream
func (*Upstream) NamespaceName ¶
func (u *Upstream) NamespaceName() tenant.NamespaceName
func (*Upstream) ProjectName ¶
func (u *Upstream) ProjectName() tenant.ProjectName
func (*Upstream) State ¶
func (u *Upstream) State() UpstreamState
func (*Upstream) Type ¶
func (u *Upstream) Type() UpstreamType
type UpstreamSpec ¶
type UpstreamSpec struct {
// contains filtered or unexported fields
}
func (UpstreamSpec) HTTPUpstreams ¶
func (s UpstreamSpec) HTTPUpstreams() []*SpecHTTPUpstream
func (UpstreamSpec) UpstreamNames ¶
func (s UpstreamSpec) UpstreamNames() []SpecUpstreamName
type UpstreamState ¶
type UpstreamState string
func (UpstreamState) String ¶
func (d UpstreamState) String() string
type UpstreamType ¶
type UpstreamType string
func UpstreamTypeFrom ¶
func UpstreamTypeFrom(str string) (UpstreamType, error)
func (UpstreamType) String ¶
func (d UpstreamType) String() string
type Upstreams ¶
type Upstreams []*Upstream
func (Upstreams) Deduplicate ¶
func (Upstreams) ToFullNameAndUpstreamMap ¶
func (Upstreams) ToResourceDestinationAndUpstreamMap ¶
type WebhookEndPoint ¶ added in v0.11.4
type WebhookSpec ¶ added in v0.11.4
type WebhookSpec struct { On string Endpoints []WebhookEndPoint }
type WithUpstream ¶
type WithUpstream struct {
// contains filtered or unexported fields
}
func NewWithUpstream ¶
func NewWithUpstream(job *Job, upstreams []*Upstream) *WithUpstream
func (WithUpstream) GetName ¶
func (w WithUpstream) GetName() string
func (WithUpstream) GetResolvedUpstreams ¶
func (w WithUpstream) GetResolvedUpstreams() []*Upstream
func (WithUpstream) GetUnresolvedUpstreams ¶
func (w WithUpstream) GetUnresolvedUpstreams() []*Upstream
func (WithUpstream) Job ¶
func (w WithUpstream) Job() *Job
func (WithUpstream) Name ¶
func (w WithUpstream) Name() Name
func (WithUpstream) Upstreams ¶
func (w WithUpstream) Upstreams() []*Upstream
type WithUpstreams ¶
type WithUpstreams []*WithUpstream
func (WithUpstreams) GetSubjectJobNames ¶
func (w WithUpstreams) GetSubjectJobNames() []Name
func (WithUpstreams) MergeWithResolvedUpstreams ¶
func (w WithUpstreams) MergeWithResolvedUpstreams(resolvedUpstreamsBySubjectJobMap map[Name][]*Upstream) []*WithUpstream
Click to show internal directories.
Click to hide internal directories.