コード例 #1
0
func (r *RunOnceRunner) StartWithSchedule(application *framework.Application, state framework.MesosState, cronScheduler framework.CronScheduler) int64 {
	id, _ := cronScheduler.AddFunc(application.StartTime, func() {
		cronScheduler.AddFunc(application.TimeSchedule, func() {
			<-r.StageApplication(application, state)
		})
	})
	return id
}
コード例 #2
0
func (r *RunOnceRunner) DeleteSchedule(id int64, cronScheduler framework.CronScheduler) {
	cronScheduler.DeleteJob(id)
}