emdb/cmd/api-service/job/job.go

33 lines
462 B
Go
Raw Normal View History

2023-12-30 09:19:53 +01:00
package job
import (
"time"
)
type JobStatus string
type Action string
const (
interval = 10 * time.Second
ActionRefreshIMDBReviews Action = "refresh-imdb-reviews"
ActionRefreshAllIMDBReviews Action = "refresh-all-imdb-reviews"
)
var (
validActions = []Action{
ActionRefreshIMDBReviews,
ActionRefreshAllIMDBReviews,
}
)
2023-12-30 09:19:53 +01:00
type Job struct {
ID int
MovieID string
Action Action
Status JobStatus
Created time.Time
Updated time.Time
2023-12-30 09:19:53 +01:00
}