diff --git a/daemons/schedule_manager.go b/daemons/schedule_manager.go index d353955..a300f50 100644 --- a/daemons/schedule_manager.go +++ b/daemons/schedule_manager.go @@ -111,11 +111,11 @@ func (s *ScheduleManager) listenForChange(nc *nats.Conn, chanName string, delete // Used at launch of the component to retrieve the next scheduled workflows // and then every X minutes in case some workflows were scheduled before launch func (s *ScheduleManager) SchedulePolling() { - var sleep_time float64 = 1 + var sleep_time float64 = 20 for { s.getNextScheduledWorkflows(1) s.Logger.Info().Msg("Current list of schedules -------> " + fmt.Sprintf("%v", len(Executions.Execs))) - time.Sleep(time.Minute * time.Duration(sleep_time)) + time.Sleep(time.Second * time.Duration(sleep_time)) } } func (s *ScheduleManager) getExecution(from time.Time, to time.Time) (exec_list []*workflow_execution.WorkflowExecution, err error) {