Documentation ¶
Index ¶
- func CancelAbandonedJobs(ctx context.Context) error
- func Cleanup(taskCtx context.Context, olderThan time.Duration) error
- func CleanupArtifacts(taskCtx context.Context) error
- func CreateAuthorizationToken(taskID, runID, jobID int64) (string, error)
- func CreateCommitStatus(ctx context.Context, jobs ...*actions_model.ActionRunJob)
- func CreateScheduleTask(ctx context.Context, cron *actions_model.ActionSchedule) error
- func DetectAndHandleSchedules(ctx context.Context, repo *repo_model.Repository) error
- func EmitJobsIfReady(runID int64) error
- func GetAllRerunJobs(job *actions_model.ActionRunJob, allJobs []*actions_model.ActionRunJob) []*actions_model.ActionRunJob
- func Init()
- func NewNotifier() notify_service.Notifier
- func ParseAuthorizationToken(req *http.Request) (int64, error)
- func StartScheduleTasks(ctx context.Context) error
- func StopEndlessTasks(ctx context.Context) error
- func StopZombieTasks(ctx context.Context) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CancelAbandonedJobs ¶
CancelAbandonedJobs cancels the jobs which have waiting status, but haven't been picked by a runner for a long time
func CleanupArtifacts ¶ added in v1.21.0
CleanupArtifacts removes expired add need-deleted artifacts and set records expired status
func CreateAuthorizationToken ¶ added in v1.22.0
func CreateCommitStatus ¶
func CreateCommitStatus(ctx context.Context, jobs ...*actions_model.ActionRunJob)
CreateCommitStatus creates a commit status for the given job. It won't return an error failed, but will log it, because it's not critical.
func CreateScheduleTask ¶ added in v1.21.0
func CreateScheduleTask(ctx context.Context, cron *actions_model.ActionSchedule) error
CreateScheduleTask creates a scheduled task from a cron action schedule. It creates an action run based on the schedule, inserts it into the database, and creates commit statuses for each job.
func DetectAndHandleSchedules ¶ added in v1.21.5
func DetectAndHandleSchedules(ctx context.Context, repo *repo_model.Repository) error
DetectAndHandleSchedules detects the schedule workflows on the default branch and create schedule tasks
func EmitJobsIfReady ¶
func GetAllRerunJobs ¶ added in v1.21.9
func GetAllRerunJobs(job *actions_model.ActionRunJob, allJobs []*actions_model.ActionRunJob) []*actions_model.ActionRunJob
GetAllRerunJobs get all jobs that need to be rerun when job should be rerun
func NewNotifier ¶
func NewNotifier() notify_service.Notifier
NewNotifier create a new actionsNotifier notifier
func ParseAuthorizationToken ¶ added in v1.22.0
func StartScheduleTasks ¶ added in v1.21.0
StartScheduleTasks start the task
func StopEndlessTasks ¶
StopEndlessTasks stops the tasks which have running status and continuous updates, but don't end for a long time
func StopZombieTasks ¶
StopZombieTasks stops the task which have running status, but haven't been updated for a long time
Types ¶
This section is empty.