Рыба проекта. Минимальная функциональность
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
package domain
|
||||
|
||||
import "context"
|
||||
|
||||
// Scheduler is the abstraction for a recurring job scheduler.
|
||||
type Scheduler interface {
|
||||
// Start begins executing the scheduled job.
|
||||
Start()
|
||||
// Stop halts the scheduler and returns a context that is cancelled
|
||||
// once all in-flight jobs have completed.
|
||||
Stop() (stoppedCtx context.Context)
|
||||
}
|
||||
Reference in New Issue
Block a user