Interface RuleScheduleService
- All Known Implementing Classes:
RuleScheduleServiceImpl
public interface RuleScheduleService
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionvoidFinds and runs all overdue schedules.voidremoveSchedule(TenantContext context, Long ruleId) Disables all schedules for a given rule.voidupdateSchedule(TenantContext context, com.codebarrel.automation.api.config.RuleConfigBean ruleConfig, com.codebarrel.automation.api.config.RuleConfigBean oldRuleConfig) Update the stored rule execution schedule for the provided rule.
-
Field Details
-
MAX_SCHEDULE_ERRORS
-
-
Method Details
-
executeAllOverdueSchedules
Finds and runs all overdue schedules. This method should execute fast and simply queue schedules to be executed (and not actually execute them)- Parameters:
env- The environment from which to retrieve schedules
-
updateSchedule
void updateSchedule(TenantContext context, com.codebarrel.automation.api.config.RuleConfigBean ruleConfig, @Nullable com.codebarrel.automation.api.config.RuleConfigBean oldRuleConfig) Update the stored rule execution schedule for the provided rule. This needs to set or remove the nextExecution time from the underlying store.- Parameters:
context- The database tenant contextruleConfig- The updated rule configurationoldRuleConfig- The previous rule configuration before the update
-
removeSchedule
Disables all schedules for a given rule.- Parameters:
context- The database tenant contextruleId- the rule to remove schedules for
-