Documentation ¶
Index ¶
- Variables
- func BoolPtr(b bool) *bool
- func HashPassword(pw string) (*string, error)
- func IsFinalJobRunStatus(status dbsqlc.JobRunStatus) bool
- func IsFinalStepRunStatus(status dbsqlc.StepRunStatus) bool
- func IsFinalWorkflowRunStatus(status dbsqlc.WorkflowRunStatus) bool
- func JobRunStatusPtr(status db.JobRunStatus) *db.JobRunStatus
- func StepRunEventReasonPtr(reason dbsqlc.StepRunEventReason) *dbsqlc.StepRunEventReason
- func StepRunEventSeverityPtr(severity dbsqlc.StepRunEventSeverity) *dbsqlc.StepRunEventSeverity
- func StepRunStatusPtr(status db.StepRunStatus) *db.StepRunStatus
- func StringPtr(s string) *string
- func VerifyPassword(hashedPW, candidate string) (bool, error)
- type APIRepository
- type APITokenRepository
- type CreateAPITokenOpts
- type CreateDispatcherOpts
- type CreateEventOpts
- type CreateGithubAppOAuthOpts
- type CreateGithubWebhookOpts
- type CreateGroupKeyRunOpts
- type CreateInstallationOpts
- type CreateLogLineOpts
- type CreateSNSIntegrationOpts
- type CreateSessionOpts
- type CreateStreamEventOpts
- type CreateTenantAlertGroupOpts
- type CreateTenantInviteOpts
- type CreateTenantMemberOpts
- type CreateTenantOpts
- type CreateTickerOpts
- type CreateUserOpts
- type CreateWorkerOpts
- type CreateWorkflowConcurrencyOpts
- type CreateWorkflowJobOpts
- type CreateWorkflowRunOpt
- type CreateWorkflowRunOpts
- func GetCreateWorkflowRunOptsFromCron(cron, cronParentId string, ...) (*CreateWorkflowRunOpts, error)
- func GetCreateWorkflowRunOptsFromEvent(eventId string, workflowVersion *dbsqlc.GetWorkflowVersionForEngineRow, ...) (*CreateWorkflowRunOpts, error)
- func GetCreateWorkflowRunOptsFromManual(workflowVersion *dbsqlc.GetWorkflowVersionForEngineRow, input []byte, ...) (*CreateWorkflowRunOpts, error)
- func GetCreateWorkflowRunOptsFromParent(workflowVersion *dbsqlc.GetWorkflowVersionForEngineRow, input []byte, ...) (*CreateWorkflowRunOpts, error)
- func GetCreateWorkflowRunOptsFromSchedule(scheduledWorkflowId string, ...) (*CreateWorkflowRunOpts, error)
- type CreateWorkflowRunPullRequestOpts
- type CreateWorkflowSchedulesOpts
- type CreateWorkflowStepOpts
- type CreateWorkflowStepRateLimitOpts
- type CreateWorkflowTagOpts
- type CreateWorkflowVersionOpts
- type DispatcherEngineRepository
- type EngineRepository
- type EngineTokenRepository
- type EventAPIRepository
- type EventEngineRepository
- type GetGroupKeyRunEngineRepository
- type GetTenantAlertingSettingsResponse
- type GetWorkflowMetricsOpts
- type GithubRepository
- type HealthRepository
- type JobRunAPIRepository
- type JobRunEngineRepository
- type JobRunHasCycleError
- type ListAllJobRunsOpts
- type ListEventOpts
- type ListEventResult
- type ListGetGroupKeyRunsOpts
- type ListLogsOpts
- type ListLogsResult
- type ListPullRequestsForWorkflowRunOpts
- type ListStepRunEventOpts
- type ListStepRunEventResult
- type ListStepRunsOpts
- type ListTenantInvitesOpts
- type ListTickerOpts
- type ListWorkersOpts
- type ListWorkflowRunRoundRobinsOpts
- type ListWorkflowRunsOpts
- type ListWorkflowRunsResult
- type ListWorkflowsOpts
- type ListWorkflowsResult
- type ListWorkflowsRow
- type LogsAPIRepository
- type LogsEngineRepository
- type OAuthOpts
- type RateLimitEngineRepository
- type SNSRepository
- type SlackRepository
- type StepRepository
- type StepRunAPIRepository
- type StepRunEngineRepository
- type StepRunUpdateInfo
- type StreamEventsEngineRepository
- type TenantAPIRepository
- type TenantAlertingAPIRepository
- type TenantAlertingEngineRepository
- type TenantEngineRepository
- type TenantInviteRepository
- type TickerEngineRepository
- type UpdateDispatcherOpts
- type UpdateGetGroupKeyRunOpts
- type UpdateInstallationOpts
- type UpdateJobRunLookupDataOpts
- type UpdatePullRequestOpts
- type UpdateSessionOpts
- type UpdateStepRunOpts
- type UpdateStepRunOverridesDataOpts
- type UpdateTenantAlertGroupOpts
- type UpdateTenantAlertingSettingsOpts
- type UpdateTenantInviteOpts
- type UpdateTenantMemberOpts
- type UpdateTenantOpts
- type UpdateTickerOpts
- type UpdateUserOpts
- type UpdateWorkerOpts
- type UpsertRateLimitOpts
- type UpsertSlackWebhookOpts
- type UpsertTenantAlertingSettingsOpts
- type UpsertWorkflowDeploymentConfigOpts
- type UserRepository
- type UserSessionRepository
- type WorkerAPIRepository
- type WorkerEngineRepository
- type WorkerWithStepCount
- type WorkflowAPIRepository
- type WorkflowEngineRepository
- type WorkflowMetrics
- type WorkflowRunAPIRepository
- type WorkflowRunEngineRepository
- type WorkflowRunMetricsCountOpts
- type WorkflowRunsMetricsOpts
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNoWorkerAvailable = fmt.Errorf("no worker available")
View Source
var ErrRateLimitExceeded = fmt.Errorf("rate limit exceeded")
View Source
var ErrStepRunIsNotPending = fmt.Errorf("step run is not pending")
Functions ¶
func HashPassword ¶
func IsFinalJobRunStatus ¶ added in v0.25.0
func IsFinalJobRunStatus(status dbsqlc.JobRunStatus) bool
func IsFinalStepRunStatus ¶ added in v0.25.0
func IsFinalStepRunStatus(status dbsqlc.StepRunStatus) bool
func IsFinalWorkflowRunStatus ¶ added in v0.25.0
func IsFinalWorkflowRunStatus(status dbsqlc.WorkflowRunStatus) bool
func JobRunStatusPtr ¶
func JobRunStatusPtr(status db.JobRunStatus) *db.JobRunStatus
func StepRunEventReasonPtr ¶ added in v0.26.0
func StepRunEventReasonPtr(reason dbsqlc.StepRunEventReason) *dbsqlc.StepRunEventReason
func StepRunEventSeverityPtr ¶ added in v0.26.0
func StepRunEventSeverityPtr(severity dbsqlc.StepRunEventSeverity) *dbsqlc.StepRunEventSeverity
func StepRunStatusPtr ¶
func StepRunStatusPtr(status db.StepRunStatus) *db.StepRunStatus
func VerifyPassword ¶
Types ¶
type APIRepository ¶ added in v0.17.0
type APIRepository interface { Health() HealthRepository APIToken() APITokenRepository Event() EventAPIRepository Log() LogsAPIRepository Tenant() TenantAPIRepository TenantAlertingSettings() TenantAlertingAPIRepository TenantInvite() TenantInviteRepository Workflow() WorkflowAPIRepository WorkflowRun() WorkflowRunAPIRepository JobRun() JobRunAPIRepository StepRun() StepRunAPIRepository Github() GithubRepository Slack() SlackRepository SNS() SNSRepository Step() StepRepository Worker() WorkerAPIRepository UserSession() UserSessionRepository User() UserRepository }
type APITokenRepository ¶ added in v0.7.0
type APITokenRepository interface { GetAPITokenById(id string) (*db.APITokenModel, error) RevokeAPIToken(id string) error ListAPITokensByTenant(tenantId string) ([]db.APITokenModel, error) }
type CreateAPITokenOpts ¶ added in v0.7.0
type CreateAPITokenOpts struct { // The id of the token ID string `validate:"required,uuid"` // When the token expires ExpiresAt time.Time // (optional) A tenant ID for this API token TenantId *string `validate:"omitempty,uuid"` // (optional) A name for this API token Name *string `validate:"omitempty,max=255"` }
type CreateDispatcherOpts ¶
type CreateDispatcherOpts struct {
ID string `validate:"required,uuid"`
}
type CreateEventOpts ¶
type CreateEventOpts struct { // (required) the tenant id TenantId string `validate:"required,uuid"` // (required) the event key Key string `validate:"required"` // (optional) the event data Data []byte // (optional) the event that this event is replaying ReplayedEvent *string `validate:"omitempty,uuid"` // (optional) the event metadata AdditionalMetadata []byte }
type CreateGithubAppOAuthOpts ¶ added in v0.11.0
type CreateGithubAppOAuthOpts struct { // (required) the oauth provider's user id GithubUserID int `validate:"required"` // (required) the oauth provider's access token AccessToken []byte `validate:"required,min=1"` // (optional) the oauth provider's refresh token RefreshToken *[]byte // (optional) the oauth provider's expiry time ExpiresAt *time.Time // (optional) the oauth provider's configuration Config *types.JSON }
type CreateGithubWebhookOpts ¶ added in v0.11.0
type CreateGithubWebhookOpts struct { // (required) the repo owner RepoOwner string `validate:"required"` // (required) the repo name RepoName string `validate:"required"` // (required) the signing secret SigningSecret []byte `validate:"required,min=1"` }
func NewGithubWebhookCreateOpts ¶ added in v0.11.0
func NewGithubWebhookCreateOpts( enc encryption.EncryptionService, repoOwner string, repoName string, ) (opts *CreateGithubWebhookOpts, signingSecret string, err error)
type CreateGroupKeyRunOpts ¶ added in v0.8.0
type CreateGroupKeyRunOpts struct { // (optional) the input data Input []byte }
type CreateInstallationOpts ¶ added in v0.11.0
type CreateInstallationOpts struct { // (required) the installation id InstallationID int `validate:"required"` // (required) the account ID AccountID int `validate:"required"` // (required) the account name AccountName string `validate:"required"` // (optional) the account avatar URL AccountAvatarURL *string // (optional) the installation settings URL InstallationSettingsURL *string // (optional) the installation configuration Config *types.JSON }
type CreateLogLineOpts ¶ added in v0.14.0
type CreateLogLineOpts struct { // The step run id StepRunId string `validate:"required,uuid"` // (optional) The time when the log line was created. CreatedAt *time.Time // (required) The message of the log line. Message string `validate:"required,min=1,max=10000"` // (optional) The level of the log line. Level *string `validate:"omitnil,oneof=INFO ERROR WARN DEBUG"` // (optional) The metadata of the log line. Metadata []byte }
type CreateSNSIntegrationOpts ¶ added in v0.15.2
type CreateSNSIntegrationOpts struct {
TopicArn string `validate:"required,min=1,max=255"`
}
type CreateSessionOpts ¶
type CreateStreamEventOpts ¶ added in v0.19.0
type CreateStreamEventOpts struct { // The step run id StepRunId string `validate:"required,uuid"` // (optional) The time when the StreamEvent was created. CreatedAt *time.Time // (required) The message of the Stream Event. Message []byte `validate:"required,min=1"` // (optional) The metadata of the Stream Event. Metadata []byte }
type CreateTenantAlertGroupOpts ¶ added in v0.25.0
type CreateTenantAlertGroupOpts struct {
Emails []string `validate:"required,dive,email,max=255"`
}
type CreateTenantInviteOpts ¶
type CreateTenantInviteOpts struct { // (required) the invitee email InviteeEmail string `validate:"required,email"` // (required) the inviter email InviterEmail string `validate:"required,email"` // (required) when the invite expires ExpiresAt time.Time `validate:"required"` // (required) the role of the invitee Role string `validate:"omitempty,oneof=OWNER ADMIN MEMBER"` }
type CreateTenantMemberOpts ¶
type CreateTenantOpts ¶
type CreateTickerOpts ¶
type CreateTickerOpts struct {
ID string `validate:"required,uuid"`
}
type CreateUserOpts ¶
type CreateWorkerOpts ¶
type CreateWorkerOpts struct { // The id of the dispatcher DispatcherId string `validate:"required,uuid"` // The maximum number of runs this worker can run at a time MaxRuns *int `validate:"omitempty,gte=1"` // The name of the worker Name string `validate:"required,hatchetName"` // The name of the service Services []string `validate:"dive,hatchetName"` // A list of actions this worker can run Actions []string `validate:"dive,actionId"` }
type CreateWorkflowConcurrencyOpts ¶ added in v0.8.0
type CreateWorkflowConcurrencyOpts struct { // (required) the action id for getting the concurrency group Action string `validate:"required,actionId"` // (optional) the maximum number of concurrent workflow runs, default 1 MaxRuns *int32 // (optional) the strategy to use when the concurrency limit is reached, default CANCEL_IN_PROGRESS LimitStrategy *string `validate:"omitnil,oneof=CANCEL_IN_PROGRESS DROP_NEWEST QUEUE_NEWEST GROUP_ROUND_ROBIN"` }
type CreateWorkflowJobOpts ¶
type CreateWorkflowJobOpts struct { // (required) the job name Name string `validate:"required,hatchetName"` // (optional) the job description Description *string // (required) the job steps Steps []CreateWorkflowStepOpts `validate:"required,min=1,dive"` Kind string `validate:"required,oneof=DEFAULT ON_FAILURE"` }
type CreateWorkflowRunOpt ¶ added in v0.18.0
type CreateWorkflowRunOpt func(*CreateWorkflowRunOpts)
func WithParent ¶ added in v0.18.0
func WithParent( parentId, parentStepRunId string, childIndex int, childKey *string, ) CreateWorkflowRunOpt
type CreateWorkflowRunOpts ¶
type CreateWorkflowRunOpts struct { // (optional) the workflow run display name DisplayName *string // (required) the workflow version id WorkflowVersionId string `validate:"required,uuid"` ManualTriggerInput *string `` /* 197-byte string literal not displayed */ // (optional) the event id that triggered the workflow run TriggeringEventId *string `` /* 204-byte string literal not displayed */ // (optional) the cron schedule that triggered the workflow run Cron *string `` /* 230-byte string literal not displayed */ CronParentId *string `` /* 230-byte string literal not displayed */ // (optional) the scheduled trigger ScheduledWorkflowId *string `` /* 200-byte string literal not displayed */ InputData []byte TriggeredBy string GetGroupKeyRun *CreateGroupKeyRunOpts `validate:"omitempty"` // (optional) the parent workflow run which this workflow run was triggered from ParentId *string `validate:"omitempty,uuid"` // (optional) the parent step run id which this workflow run was triggered from ParentStepRunId *string `validate:"omitempty,uuid"` // (optional) the child key of the workflow run, if this is a child run of a different workflow ChildKey *string // (optional) the child index of the workflow run, if this is a child run of a different workflow ChildIndex *int // (optional) additional metadata for the workflow run AdditionalMetadata map[string]interface{} `validate:"omitempty"` }
func GetCreateWorkflowRunOptsFromCron ¶
func GetCreateWorkflowRunOptsFromCron( cron, cronParentId string, workflowVersion *dbsqlc.GetWorkflowVersionForEngineRow, input []byte, additionalMetadata map[string]interface{}, ) (*CreateWorkflowRunOpts, error)
func GetCreateWorkflowRunOptsFromEvent ¶
func GetCreateWorkflowRunOptsFromEvent( eventId string, workflowVersion *dbsqlc.GetWorkflowVersionForEngineRow, input []byte, additionalMetadata map[string]interface{}, ) (*CreateWorkflowRunOpts, error)
func GetCreateWorkflowRunOptsFromManual ¶ added in v0.9.0
func GetCreateWorkflowRunOptsFromManual( workflowVersion *dbsqlc.GetWorkflowVersionForEngineRow, input []byte, additionalMetadata map[string]interface{}, ) (*CreateWorkflowRunOpts, error)
func GetCreateWorkflowRunOptsFromParent ¶ added in v0.18.0
func GetCreateWorkflowRunOptsFromParent( workflowVersion *dbsqlc.GetWorkflowVersionForEngineRow, input []byte, parentId, parentStepRunId string, childIndex int, childKey *string, additionalMetadata map[string]interface{}, ) (*CreateWorkflowRunOpts, error)
func GetCreateWorkflowRunOptsFromSchedule ¶
func GetCreateWorkflowRunOptsFromSchedule( scheduledWorkflowId string, workflowVersion *dbsqlc.GetWorkflowVersionForEngineRow, input []byte, additionalMetadata map[string]interface{}, fs ...CreateWorkflowRunOpt, ) (*CreateWorkflowRunOpts, error)
type CreateWorkflowRunPullRequestOpts ¶ added in v0.11.0
type CreateWorkflowStepOpts ¶
type CreateWorkflowStepOpts struct { // (required) the step name ReadableId string `validate:"hatchetName"` // (required) the step action id Action string `validate:"required,actionId"` // (optional) the step timeout Timeout *string `validate:"omitnil,duration"` // (optional) the parents that this step depends on Parents []string `validate:"dive,hatchetName"` // (optional) the custom user data for the step, serialized as a json string UserData *string `validate:"omitnil,json"` // (optional) the step retry max Retries *int `validate:"omitempty,min=0"` // (optional) rate limits for this step RateLimits []CreateWorkflowStepRateLimitOpts `validate:"dive"` }
type CreateWorkflowStepRateLimitOpts ¶ added in v0.19.0
type CreateWorkflowTagOpts ¶
type CreateWorkflowVersionOpts ¶
type CreateWorkflowVersionOpts struct { // (required) the workflow name Name string `validate:"required,hatchetName"` Tags []CreateWorkflowTagOpts `validate:"dive"` // (optional) the workflow description Description *string `json:"description,omitempty"` // (optional) the workflow version Version *string `json:"version,omitempty"` // (optional) event triggers for the workflow EventTriggers []string // (optional) cron triggers for the workflow CronTriggers []string `validate:"dive,cron"` // (optional) the input bytes for the cron triggers CronInput []byte // (optional) scheduled triggers for the workflow ScheduledTriggers []time.Time // (required) the workflow jobs Jobs []CreateWorkflowJobOpts `validate:"required,min=1,dive"` OnFailureJob *CreateWorkflowJobOpts `json:"onFailureJob,omitempty" validate:"omitempty"` // (optional) the workflow concurrency groups Concurrency *CreateWorkflowConcurrencyOpts `json:"concurrency,omitempty" validator:"omitnil"` // (optional) the amount of time for step runs to wait to be scheduled before timing out ScheduleTimeout *string `validate:"omitempty,duration"` }
func (*CreateWorkflowVersionOpts) Checksum ¶ added in v0.7.0
func (o *CreateWorkflowVersionOpts) Checksum() (string, error)
type DispatcherEngineRepository ¶ added in v0.17.0
type DispatcherEngineRepository interface { // CreateNewDispatcher creates a new dispatcher for a given tenant. CreateNewDispatcher(ctx context.Context, opts *CreateDispatcherOpts) (*dbsqlc.Dispatcher, error) // UpdateDispatcher updates a dispatcher for a given tenant. UpdateDispatcher(ctx context.Context, dispatcherId string, opts *UpdateDispatcherOpts) (*dbsqlc.Dispatcher, error) Delete(ctx context.Context, dispatcherId string) error UpdateStaleDispatchers(ctx context.Context, onStale func(dispatcherId string, getValidDispatcherId func() string) error) error }
type EngineRepository ¶ added in v0.17.0
type EngineRepository interface { Health() HealthRepository APIToken() EngineTokenRepository Dispatcher() DispatcherEngineRepository Event() EventEngineRepository GetGroupKeyRun() GetGroupKeyRunEngineRepository JobRun() JobRunEngineRepository StepRun() StepRunEngineRepository Tenant() TenantEngineRepository TenantAlertingSettings() TenantAlertingEngineRepository Ticker() TickerEngineRepository Worker() WorkerEngineRepository Workflow() WorkflowEngineRepository WorkflowRun() WorkflowRunEngineRepository StreamEvent() StreamEventsEngineRepository Log() LogsEngineRepository RateLimit() RateLimitEngineRepository }
type EngineTokenRepository ¶ added in v0.17.0
type EventAPIRepository ¶ added in v0.17.0
type EventAPIRepository interface { // ListEvents returns all events for a given tenant. ListEvents(tenantId string, opts *ListEventOpts) (*ListEventResult, error) // ListEventKeys returns all unique event keys for a given tenant. ListEventKeys(tenantId string) ([]string, error) // GetEventById returns an event by id. GetEventById(id string) (*db.EventModel, error) // ListEventsById returns a list of events by id. ListEventsById(tenantId string, ids []string) ([]db.EventModel, error) }
type EventEngineRepository ¶ added in v0.17.0
type EventEngineRepository interface { // CreateEvent creates a new event for a given tenant. CreateEvent(ctx context.Context, opts *CreateEventOpts) (*dbsqlc.Event, error) // GetEventForEngine returns an event for the engine by id. GetEventForEngine(ctx context.Context, tenantId, id string) (*dbsqlc.Event, error) ListEventsByIds(ctx context.Context, tenantId string, ids []string) ([]*dbsqlc.Event, error) }
type GetGroupKeyRunEngineRepository ¶ added in v0.17.0
type GetGroupKeyRunEngineRepository interface { // ListStepRunsToRequeue returns a list of step runs which are in a requeueable state. ListGetGroupKeyRunsToRequeue(ctx context.Context, tenantId string) ([]*dbsqlc.GetGroupKeyRun, error) ListGetGroupKeyRunsToReassign(ctx context.Context, tenantId string) ([]*dbsqlc.GetGroupKeyRun, error) AssignGetGroupKeyRunToWorker(ctx context.Context, tenantId, getGroupKeyRunId string) (workerId string, dispatcherId string, err error) AssignGetGroupKeyRunToTicker(ctx context.Context, tenantId, getGroupKeyRunId string) (tickerId string, err error) UpdateGetGroupKeyRun(ctx context.Context, tenantId, getGroupKeyRunId string, opts *UpdateGetGroupKeyRunOpts) (*dbsqlc.GetGroupKeyRunForEngineRow, error) GetGroupKeyRunForEngine(ctx context.Context, tenantId, getGroupKeyRunId string) (*dbsqlc.GetGroupKeyRunForEngineRow, error) }
type GetTenantAlertingSettingsResponse ¶ added in v0.25.0
type GetTenantAlertingSettingsResponse struct { Settings *dbsqlc.TenantAlertingSettings SlackWebhooks []*dbsqlc.SlackAppWebhook EmailGroups []*dbsqlc.TenantAlertEmailGroup Tenant *dbsqlc.Tenant }
type GetWorkflowMetricsOpts ¶ added in v0.19.3
type GithubRepository ¶ added in v0.11.0
type GithubRepository interface { CreateInstallation(githubUserId int, opts *CreateInstallationOpts) (*db.GithubAppInstallationModel, error) AddGithubUserIdToInstallation(installationID, accountID, githubUserId int) (*db.GithubAppInstallationModel, error) ReadGithubAppInstallationByID(installationId string) (*db.GithubAppInstallationModel, error) ReadGithubWebhookById(id string) (*db.GithubWebhookModel, error) ReadGithubWebhook(tenantId, repoOwner, repoName string) (*db.GithubWebhookModel, error) ReadGithubAppOAuthByGithubUserID(githubUserID int) (*db.GithubAppOAuthModel, error) CanUserAccessInstallation(installationId, userId string) (bool, error) ReadGithubAppInstallationByInstallationAndAccountID(installationID, accountID int) (*db.GithubAppInstallationModel, error) CreateGithubWebhook(tenantId string, opts *CreateGithubWebhookOpts) (*db.GithubWebhookModel, error) UpsertGithubAppOAuth(userId string, opts *CreateGithubAppOAuthOpts) (*db.GithubAppOAuthModel, error) DeleteInstallation(installationId, accountId int) (*db.GithubAppInstallationModel, error) ListGithubAppInstallationsByUserID(userId string) ([]db.GithubAppInstallationModel, error) UpdatePullRequest(tenantId, prId string, opts *UpdatePullRequestOpts) (*db.GithubPullRequestModel, error) GetPullRequest(tenantId, repoOwner, repoName string, prNumber int) (*db.GithubPullRequestModel, error) }
type HealthRepository ¶ added in v0.13.0
type HealthRepository interface {
IsHealthy() bool
}
type JobRunAPIRepository ¶ added in v0.17.0
type JobRunEngineRepository ¶ added in v0.17.0
type JobRunEngineRepository interface { // SetJobRunStatusRunning resets the status of a job run to a RUNNING status. This is useful if a step // run is being manually replayed, but shouldn't be used by most callers. SetJobRunStatusRunning(ctx context.Context, tenantId, jobRunId string) error ListJobRunsForWorkflowRun(ctx context.Context, tenantId, workflowRunId string) ([]*dbsqlc.ListJobRunsForWorkflowRunRow, error) GetJobRunByWorkflowRunIdAndJobId(ctx context.Context, tenantId, workflowRunId, jobId string) (*dbsqlc.GetJobRunByWorkflowRunIdAndJobIdRow, error) }
type JobRunHasCycleError ¶
type JobRunHasCycleError struct {
JobName string
}
func (*JobRunHasCycleError) Error ¶
func (e *JobRunHasCycleError) Error() string
type ListAllJobRunsOpts ¶
type ListAllJobRunsOpts struct { TickerId *string NoTickerId *bool Status *db.JobRunStatus }
type ListEventOpts ¶
type ListEventOpts struct { // (optional) a list of event keys to filter by Keys []string // (optional) a list of workflow IDs to filter by Workflows []string // (optional) a list of workflow run statuses to filter by WorkflowRunStatus []db.WorkflowRunStatus // (optional) number of events to skip Offset *int // (optional) number of events to return Limit *int // (optional) a search query Search *string // (optional) the event that this event is replaying ReplayedEvent *string `validate:"omitempty,uuid"` // (optional) the order by field OrderBy *string `validate:"omitempty,oneof=createdAt"` // (optional) the order direction OrderDirection *string `validate:"omitempty,oneof=ASC DESC"` // (optional) the event metadata AdditionalMetadata []byte }
type ListEventResult ¶
type ListEventResult struct { Rows []*dbsqlc.ListEventsRow Count int }
type ListGetGroupKeyRunsOpts ¶ added in v0.8.0
type ListGetGroupKeyRunsOpts struct {
Status *db.StepRunStatus
}
type ListLogsOpts ¶ added in v0.14.0
type ListLogsOpts struct { // (optional) number of logs to skip Offset *int // (optional) number of logs to return Limit *int `validate:"omitnil,min=1,max=1000"` // (optional) a list of log levels to filter by Levels []string `validate:"omitnil,dive,oneof=INFO ERROR WARN DEBUG"` // (optional) a step run id to filter by StepRunId *string `validate:"omitempty,uuid"` // (optional) a search query Search *string // (optional) the order by field OrderBy *string `validate:"omitempty,oneof=createdAt"` // (optional) the order direction OrderDirection *string `validate:"omitempty,oneof=ASC DESC"` }
type ListLogsResult ¶ added in v0.14.0
type ListPullRequestsForWorkflowRunOpts ¶ added in v0.11.0
type ListPullRequestsForWorkflowRunOpts struct {
State *string
}
type ListStepRunEventOpts ¶ added in v0.26.0
type ListStepRunEventResult ¶ added in v0.26.0
type ListStepRunEventResult struct { Rows []*dbsqlc.StepRunEvent Count int }
type ListStepRunsOpts ¶
type ListStepRunsOpts struct { JobRunId *string `validate:"omitempty,uuid"` WorkflowRunIds []string `validate:"dive,uuid"` Status *dbsqlc.StepRunStatus }
type ListTenantInvitesOpts ¶
type ListTickerOpts ¶
type ListWorkersOpts ¶
type ListWorkflowRunRoundRobinsOpts ¶ added in v0.12.0
type ListWorkflowRunRoundRobinsOpts struct { // (optional) the workflow id WorkflowId *string `validate:"omitempty,uuid"` // (optional) the workflow version id WorkflowVersionId *string `validate:"omitempty,uuid"` // (optional) the status of the workflow run Status *db.WorkflowRunStatus // (optional) number of events to skip Offset *int // (optional) number of events to return Limit *int }
type ListWorkflowRunsOpts ¶
type ListWorkflowRunsOpts struct { // (optional) the workflow id WorkflowId *string `validate:"omitempty,uuid"` // (optional) the workflow version id WorkflowVersionId *string `validate:"omitempty,uuid"` // (optional) a list of workflow run ids to filter by Ids []string `validate:"omitempty,dive,uuid"` // (optional) the parent workflow run id ParentId *string `validate:"omitempty,uuid"` // (optional) the parent step run id ParentStepRunId *string `validate:"omitempty,uuid"` // (optional) the event id that triggered the workflow run EventId *string `validate:"omitempty,uuid"` // (optional) the group key for the workflow run GroupKey *string // (optional) the status of the workflow run Statuses *[]db.WorkflowRunStatus // (optional) number of events to skip Offset *int // (optional) number of events to return Limit *int // (optional) the order by field OrderBy *string `validate:"omitempty,oneof=createdAt"` // (optional) the order direction OrderDirection *string `validate:"omitempty,oneof=ASC DESC"` // (optional) a time after which the run was created CreatedAfter *time.Time // (optional) a time before which the run was finished FinishedAfter *time.Time // (optional) exact metadata to filter by AdditionalMetadata map[string]interface{} `validate:"omitempty"` }
type ListWorkflowRunsResult ¶
type ListWorkflowRunsResult struct { Rows []*dbsqlc.ListWorkflowRunsRow Count int }
type ListWorkflowsOpts ¶
type ListWorkflowsResult ¶
type ListWorkflowsResult struct { Rows []*ListWorkflowsRow Count int }
type ListWorkflowsRow ¶
type ListWorkflowsRow struct { *db.WorkflowModel LatestRun *db.WorkflowRunModel }
type LogsAPIRepository ¶ added in v0.17.0
type LogsAPIRepository interface { // ListLogLines returns a list of log lines for a given step run. ListLogLines(tenantId string, opts *ListLogsOpts) (*ListLogsResult, error) }
type LogsEngineRepository ¶ added in v0.17.0
type RateLimitEngineRepository ¶ added in v0.19.0
type SNSRepository ¶ added in v0.15.0
type SNSRepository interface { GetSNSIntegration(tenantId, topicArn string) (*db.SNSIntegrationModel, error) GetSNSIntegrationById(id string) (*db.SNSIntegrationModel, error) CreateSNSIntegration(tenantId string, opts *CreateSNSIntegrationOpts) (*db.SNSIntegrationModel, error) ListSNSIntegrations(tenantId string) ([]db.SNSIntegrationModel, error) DeleteSNSIntegration(tenantId, id string) error }
type SlackRepository ¶ added in v0.25.0
type SlackRepository interface { UpsertSlackWebhook(tenantId string, opts *UpsertSlackWebhookOpts) (*db.SlackAppWebhookModel, error) ListSlackWebhooks(tenantId string) ([]db.SlackAppWebhookModel, error) GetSlackWebhookById(id string) (*db.SlackAppWebhookModel, error) DeleteSlackWebhook(tenantId string, id string) error }
type StepRepository ¶
type StepRunAPIRepository ¶ added in v0.17.0
type StepRunAPIRepository interface { GetStepRunById(tenantId, stepRunId string) (*db.StepRunModel, error) GetFirstArchivedStepRunResult(tenantId, stepRunId string) (*db.StepRunResultArchiveModel, error) ListStepRunEvents(stepRunId string, opts *ListStepRunEventOpts) (*ListStepRunEventResult, error) }
type StepRunEngineRepository ¶ added in v0.17.0
type StepRunEngineRepository interface { // ListStepRunsForWorkflowRun returns a list of step runs for a workflow run. ListStepRuns(ctx context.Context, tenantId string, opts *ListStepRunsOpts) ([]*dbsqlc.GetStepRunForEngineRow, error) // ListStepRunsToRequeue returns a list of step runs which are in a requeueable state. ListStepRunsToRequeue(ctx context.Context, tenantId string) ([]*dbsqlc.GetStepRunForEngineRow, error) // ListStepRunsToReassign returns a list of step runs which are in a reassignable state. ListStepRunsToReassign(ctx context.Context, tenantId string) ([]*dbsqlc.GetStepRunForEngineRow, error) UpdateStepRun(ctx context.Context, tenantId, stepRunId string, opts *UpdateStepRunOpts) (*dbsqlc.GetStepRunForEngineRow, *StepRunUpdateInfo, error) UnlinkStepRunFromWorker(ctx context.Context, tenantId, stepRunId string) error // UpdateStepRunOverridesData updates the overrides data field in the input for a step run. This returns the input // bytes. UpdateStepRunOverridesData(ctx context.Context, tenantId, stepRunId string, opts *UpdateStepRunOverridesDataOpts) ([]byte, error) UpdateStepRunInputSchema(ctx context.Context, tenantId, stepRunId string, schema []byte) ([]byte, error) AssignStepRunToWorker(ctx context.Context, stepRun *dbsqlc.GetStepRunForEngineRow) (workerId string, dispatcherId string, err error) GetStepRunForEngine(ctx context.Context, tenantId, stepRunId string) (*dbsqlc.GetStepRunForEngineRow, error) // QueueStepRun is like UpdateStepRun, except that it will only update the step run if it is in // a pending state. QueueStepRun(ctx context.Context, tenantId, stepRunId string, opts *UpdateStepRunOpts) (*dbsqlc.GetStepRunForEngineRow, error) ListStartableStepRuns(ctx context.Context, tenantId, jobRunId string, parentStepRunId *string) ([]*dbsqlc.GetStepRunForEngineRow, error) ArchiveStepRunResult(ctx context.Context, tenantId, stepRunId string) error }
type StepRunUpdateInfo ¶ added in v0.10.2
type StreamEventsEngineRepository ¶ added in v0.19.0
type StreamEventsEngineRepository interface { // PutStreamEvent creates a new StreamEvent line. PutStreamEvent(ctx context.Context, tenantId string, opts *CreateStreamEventOpts) (*dbsqlc.StreamEvent, error) // GetStreamEvent returns a StreamEvent line by id. GetStreamEvent(ctx context.Context, tenantId string, streamEventId int64) (*dbsqlc.StreamEvent, error) // CleanupStreamEvents deletes all stale StreamEvents. CleanupStreamEvents(ctx context.Context) error }
type TenantAPIRepository ¶ added in v0.17.0
type TenantAPIRepository interface { // CreateTenant creates a new tenant. CreateTenant(opts *CreateTenantOpts) (*db.TenantModel, error) // CreateTenant creates a new tenant. UpdateTenant(tenantId string, opts *UpdateTenantOpts) (*db.TenantModel, error) // GetTenantByID returns the tenant with the given id GetTenantByID(tenantId string) (*db.TenantModel, error) // GetTenantBySlug returns the tenant with the given slug GetTenantBySlug(slug string) (*db.TenantModel, error) // CreateTenantMember creates a new member in the tenant CreateTenantMember(tenantId string, opts *CreateTenantMemberOpts) (*db.TenantMemberModel, error) // GetTenantMemberByID returns the tenant member with the given id GetTenantMemberByID(memberId string) (*db.TenantMemberModel, error) // GetTenantMemberByUserID returns the tenant member with the given user id GetTenantMemberByUserID(tenantId string, userId string) (*db.TenantMemberModel, error) // GetTenantMemberByEmail returns the tenant member with the given email GetTenantMemberByEmail(tenantId string, email string) (*db.TenantMemberModel, error) // ListTenantMembers returns the list of tenant members for the given tenant ListTenantMembers(tenantId string) ([]db.TenantMemberModel, error) // UpdateTenantMember updates the tenant member with the given id UpdateTenantMember(memberId string, opts *UpdateTenantMemberOpts) (*db.TenantMemberModel, error) // DeleteTenantMember deletes the tenant member with the given id DeleteTenantMember(memberId string) (*db.TenantMemberModel, error) }
type TenantAlertingAPIRepository ¶ added in v0.25.0
type TenantAlertingAPIRepository interface { UpsertTenantAlertingSettings(tenantId string, opts *UpsertTenantAlertingSettingsOpts) (*db.TenantAlertingSettingsModel, error) GetTenantAlertingSettings(tenantId string) (*db.TenantAlertingSettingsModel, error) CreateTenantAlertGroup(tenantId string, opts *CreateTenantAlertGroupOpts) (*db.TenantAlertEmailGroupModel, error) UpdateTenantAlertGroup(id string, opts *UpdateTenantAlertGroupOpts) (*db.TenantAlertEmailGroupModel, error) ListTenantAlertGroups(tenantId string) ([]db.TenantAlertEmailGroupModel, error) GetTenantAlertGroupById(id string) (*db.TenantAlertEmailGroupModel, error) DeleteTenantAlertGroup(tenantId string, id string) error }
type TenantAlertingEngineRepository ¶ added in v0.25.0
type TenantAlertingEngineRepository interface { GetTenantAlertingSettings(ctx context.Context, tenantId string) (*GetTenantAlertingSettingsResponse, error) UpdateTenantAlertingSettings(ctx context.Context, tenantId string, opts *UpdateTenantAlertingSettingsOpts) error }
type TenantEngineRepository ¶ added in v0.17.0
type TenantInviteRepository ¶
type TenantInviteRepository interface { // CreateTenantInvite creates a new tenant invite with the given options CreateTenantInvite(tenantId string, opts *CreateTenantInviteOpts) (*db.TenantInviteLinkModel, error) // GetTenantInvite returns the tenant invite with the given id GetTenantInvite(id string) (*db.TenantInviteLinkModel, error) // ListTenantInvitesByEmail returns the list of tenant invites for the given invitee email for invites // which are not expired ListTenantInvitesByEmail(email string) ([]db.TenantInviteLinkModel, error) // ListTenantInvitesByTenantId returns the list of tenant invites for the given tenant id ListTenantInvitesByTenantId(tenantId string, opts *ListTenantInvitesOpts) ([]db.TenantInviteLinkModel, error) // UpdateTenantInvite updates the tenant invite with the given id UpdateTenantInvite(id string, opts *UpdateTenantInviteOpts) (*db.TenantInviteLinkModel, error) // DeleteTenantInvite deletes the tenant invite with the given id DeleteTenantInvite(id string) error }
type TickerEngineRepository ¶ added in v0.17.0
type TickerEngineRepository interface { // CreateNewTicker creates a new ticker. CreateNewTicker(ctx context.Context, opts *CreateTickerOpts) (*dbsqlc.Ticker, error) // UpdateTicker updates a ticker. UpdateTicker(ctx context.Context, tickerId string, opts *UpdateTickerOpts) (*dbsqlc.Ticker, error) // ListTickers lists tickers. ListTickers(ctx context.Context, opts *ListTickerOpts) ([]*dbsqlc.Ticker, error) // Delete deletes a ticker. Delete(ctx context.Context, tickerId string) error // PollStepRuns looks for step runs who are close to past their timeoutAt value and are in a running state PollStepRuns(ctx context.Context, tickerId string) ([]*dbsqlc.StepRun, error) // PollJobRuns looks for get group key runs who are close to past their timeoutAt value and are in a running state PollGetGroupKeyRuns(ctx context.Context, tickerId string) ([]*dbsqlc.GetGroupKeyRun, error) // PollCronSchedules returns all cron schedules which should be managed by the ticker PollCronSchedules(ctx context.Context, tickerId string) ([]*dbsqlc.PollCronSchedulesRow, error) PollScheduledWorkflows(ctx context.Context, tickerId string) ([]*dbsqlc.PollScheduledWorkflowsRow, error) PollTenantAlerts(ctx context.Context, tickerId string) ([]*dbsqlc.PollTenantAlertsRow, error) }
type UpdateDispatcherOpts ¶
type UpdateGetGroupKeyRunOpts ¶ added in v0.8.0
type UpdateInstallationOpts ¶ added in v0.11.0
type UpdateInstallationOpts struct { }
type UpdatePullRequestOpts ¶ added in v0.11.0
type UpdateSessionOpts ¶
type UpdateStepRunOpts ¶
type UpdateStepRunOpts struct { IsRerun bool RequeueAfter *time.Time ScheduleTimeoutAt *time.Time Status *db.StepRunStatus StartedAt *time.Time FailedAt *time.Time FinishedAt *time.Time CancelledAt *time.Time CancelledReason *string Error *string Input []byte Output []byte RetryCount *int EventMessage *string EventReason *dbsqlc.StepRunEventReason EventSeverity *dbsqlc.StepRunEventSeverity }
type UpdateStepRunOverridesDataOpts ¶ added in v0.11.0
type UpdateTenantAlertGroupOpts ¶ added in v0.25.0
type UpdateTenantAlertGroupOpts struct {
Emails []string `validate:"required,dive,email,max=255"`
}
type UpdateTenantAlertingSettingsOpts ¶ added in v0.25.0
type UpdateTenantInviteOpts ¶
type UpdateTenantMemberOpts ¶
type UpdateTenantMemberOpts struct {
Role *string `validate:"omitempty,oneof=OWNER ADMIN MEMBER"`
}
type UpdateTenantOpts ¶ added in v0.23.0
type UpdateTickerOpts ¶
type UpdateUserOpts ¶
type UpdateWorkerOpts ¶
type UpsertRateLimitOpts ¶ added in v0.19.0
type UpsertSlackWebhookOpts ¶ added in v0.25.0
type UpsertTenantAlertingSettingsOpts ¶ added in v0.25.0
type UpsertTenantAlertingSettingsOpts struct {
MaxFrequency *string `validate:"omitnil,duration"`
}
type UpsertWorkflowDeploymentConfigOpts ¶ added in v0.11.0
type UpsertWorkflowDeploymentConfigOpts struct { // (required) the github app installation id GithubAppInstallationId string `validate:"required,uuid"` // (required) the github repository name GitRepoName string `validate:"required"` // (required) the github repository owner GitRepoOwner string `validate:"required"` // (required) the github repository branch GitRepoBranch string `validate:"required"` }
type UserRepository ¶
type UserRepository interface { // GetUserByID returns the user with the given id GetUserByID(id string) (*db.UserModel, error) // GetUserByEmail returns the user with the given email GetUserByEmail(email string) (*db.UserModel, error) // GetUserPassword returns the user password with the given id GetUserPassword(id string) (*db.UserPasswordModel, error) // CreateUser creates a new user with the given options CreateUser(*CreateUserOpts) (*db.UserModel, error) // UpdateUser updates the user with the given email UpdateUser(id string, opts *UpdateUserOpts) (*db.UserModel, error) // ListTenantMemberships returns the list of tenant memberships for the given user ListTenantMemberships(userId string) ([]db.TenantMemberModel, error) }
type UserSessionRepository ¶
type UserSessionRepository interface { Create(opts *CreateSessionOpts) (*db.UserSessionModel, error) Update(sessionId string, opts *UpdateSessionOpts) (*db.UserSessionModel, error) Delete(sessionId string) (*db.UserSessionModel, error) GetById(sessionId string) (*db.UserSessionModel, error) }
UserSessionRepository represents the set of queries on the UserSession model
type WorkerAPIRepository ¶ added in v0.17.0
type WorkerAPIRepository interface { // ListWorkers lists workers for the tenant ListWorkers(tenantId string, opts *ListWorkersOpts) ([]*dbsqlc.ListWorkersWithStepCountRow, error) // ListRecentWorkerStepRuns lists recent step runs for a given worker ListRecentWorkerStepRuns(tenantId, workerId string) ([]db.StepRunModel, error) // GetWorkerById returns a worker by its id. GetWorkerById(workerId string) (*db.WorkerModel, error) }
type WorkerEngineRepository ¶ added in v0.17.0
type WorkerEngineRepository interface { // CreateNewWorker creates a new worker for a given tenant. CreateNewWorker(ctx context.Context, tenantId string, opts *CreateWorkerOpts) (*dbsqlc.Worker, error) // UpdateWorker updates a worker for a given tenant. UpdateWorker(ctx context.Context, tenantId, workerId string, opts *UpdateWorkerOpts) (*dbsqlc.Worker, error) // DeleteWorker removes the worker from the database DeleteWorker(ctx context.Context, tenantId, workerId string) error GetWorkerForEngine(ctx context.Context, tenantId, workerId string) (*dbsqlc.GetWorkerForEngineRow, error) }
type WorkerWithStepCount ¶
type WorkerWithStepCount struct { Worker *db.WorkerModel StepRunCount int }
type WorkflowAPIRepository ¶ added in v0.17.0
type WorkflowAPIRepository interface { // ListWorkflows returns all workflows for a given tenant. ListWorkflows(tenantId string, opts *ListWorkflowsOpts) (*ListWorkflowsResult, error) // GetWorkflowById returns a workflow by its name. It will return db.ErrNotFound if the workflow does not exist. GetWorkflowById(workflowId string) (*db.WorkflowModel, error) // GetWorkflowByName returns a workflow by its name. It will return db.ErrNotFound if the workflow does not exist. GetWorkflowByName(tenantId, workflowName string) (*db.WorkflowModel, error) // GetWorkflowVersionById returns a workflow version by its id. It will return db.ErrNotFound if the workflow // version does not exist. GetWorkflowVersionById(tenantId, workflowId string) (*db.WorkflowVersionModel, error) // DeleteWorkflow deletes a workflow for a given tenant. DeleteWorkflow(tenantId, workflowId string) (*db.WorkflowModel, error) // GetWorkflowVersionMetrics returns the metrics for a given workflow version. GetWorkflowMetrics(tenantId, workflowId string, opts *GetWorkflowMetricsOpts) (*WorkflowMetrics, error) UpsertWorkflowDeploymentConfig(workflowId string, opts *UpsertWorkflowDeploymentConfigOpts) (*db.WorkflowDeploymentConfigModel, error) }
type WorkflowEngineRepository ¶ added in v0.17.0
type WorkflowEngineRepository interface { // CreateNewWorkflow creates a new workflow for a given tenant. It will create the parent // workflow based on the version's name. CreateNewWorkflow(ctx context.Context, tenantId string, opts *CreateWorkflowVersionOpts) (*dbsqlc.GetWorkflowVersionForEngineRow, error) // CreateWorkflowVersion creates a new workflow version for a given tenant. This will fail if there is // not a parent workflow with the same name already in the database. CreateWorkflowVersion(ctx context.Context, tenantId string, opts *CreateWorkflowVersionOpts) (*dbsqlc.GetWorkflowVersionForEngineRow, error) // CreateSchedules creates schedules for a given workflow version. CreateSchedules(ctx context.Context, tenantId, workflowVersionId string, opts *CreateWorkflowSchedulesOpts) ([]*dbsqlc.WorkflowTriggerScheduledRef, error) GetLatestWorkflowVersion(ctx context.Context, tenantId, workflowId string) (*dbsqlc.GetWorkflowVersionForEngineRow, error) // GetWorkflowByName returns a workflow by its name. It will return db.ErrNotFound if the workflow does not exist. GetWorkflowByName(ctx context.Context, tenantId, workflowName string) (*dbsqlc.Workflow, error) // ListWorkflowsForEvent returns the latest workflow versions for a given tenant that are triggered by the // given event. ListWorkflowsForEvent(ctx context.Context, tenantId, eventKey string) ([]*dbsqlc.GetWorkflowVersionForEngineRow, error) // GetWorkflowVersionById returns a workflow version by its id. It will return db.ErrNotFound if the workflow // version does not exist. GetWorkflowVersionById(ctx context.Context, tenantId, workflowId string) (*dbsqlc.GetWorkflowVersionForEngineRow, error) }
type WorkflowMetrics ¶ added in v0.19.3
type WorkflowRunAPIRepository ¶ added in v0.17.0
type WorkflowRunAPIRepository interface { // ListWorkflowRuns returns workflow runs for a given workflow version id. ListWorkflowRuns(tenantId string, opts *ListWorkflowRunsOpts) (*ListWorkflowRunsResult, error) // Counts by status WorkflowRunMetricsCount(tenantId string, opts *WorkflowRunsMetricsOpts) (*dbsqlc.WorkflowRunsMetricsCountRow, error) // CreateNewWorkflowRun creates a new workflow run for a workflow version. CreateNewWorkflowRun(ctx context.Context, tenantId string, opts *CreateWorkflowRunOpts) (*db.WorkflowRunModel, error) // GetWorkflowRunById returns a workflow run by id. GetWorkflowRunById(tenantId, runId string) (*db.WorkflowRunModel, error) CreateWorkflowRunPullRequest(tenantId, workflowRunId string, opts *CreateWorkflowRunPullRequestOpts) (*db.GithubPullRequestModel, error) ListPullRequestsForWorkflowRun(tenantId, workflowRunId string, opts *ListPullRequestsForWorkflowRunOpts) ([]db.GithubPullRequestModel, error) }
type WorkflowRunEngineRepository ¶ added in v0.17.0
type WorkflowRunEngineRepository interface { // ListWorkflowRuns returns workflow runs for a given workflow version id. ListWorkflowRuns(ctx context.Context, tenantId string, opts *ListWorkflowRunsOpts) (*ListWorkflowRunsResult, error) GetChildWorkflowRun(ctx context.Context, parentId, parentStepRunId string, childIndex int, childkey *string) (*dbsqlc.WorkflowRun, error) GetScheduledChildWorkflowRun(ctx context.Context, parentId, parentStepRunId string, childIndex int, childkey *string) (*dbsqlc.WorkflowTriggerScheduledRef, error) PopWorkflowRunsRoundRobin(ctx context.Context, tenantId, workflowId string, maxRuns int) ([]*dbsqlc.WorkflowRun, error) // CreateNewWorkflowRun creates a new workflow run for a workflow version. CreateNewWorkflowRun(ctx context.Context, tenantId string, opts *CreateWorkflowRunOpts) (string, error) // GetWorkflowRunById returns a workflow run by id. GetWorkflowRunById(ctx context.Context, tenantId, runId string) (*dbsqlc.GetWorkflowRunRow, error) }
type WorkflowRunMetricsCountOpts ¶ added in v0.22.0
type WorkflowRunsMetricsOpts ¶ added in v0.22.0
type WorkflowRunsMetricsOpts struct { // (optional) the workflow id WorkflowId *string `validate:"omitempty,uuid"` // (optional) the workflow version id WorkflowVersionId *string `validate:"omitempty,uuid"` // (optional) the parent workflow run id ParentId *string `validate:"omitempty,uuid"` // (optional) the parent step run id ParentStepRunId *string `validate:"omitempty,uuid"` // (optional) the event id that triggered the workflow run EventId *string `validate:"omitempty,uuid"` // (optional) exact metadata to filter by AdditionalMetadata map[string]interface{} `validate:"omitempty"` }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.