Package com.github.kagkarlsson.scheduler
Interface TaskRepository
- All Known Implementing Classes:
JdbcTaskRepository
public interface TaskRepository
-
Method Summary
Modifier and TypeMethodDescriptionvoidcreateBatch(List<ScheduledTaskInstance> executions) booleancreateIfNotExists(SchedulableInstance<?> execution) Deprecated.booleancreateIfNotExists(ScheduledTaskInstance execution) getDeadExecutions(Instant olderThan) getExecution(TaskInstanceId taskInstance) getExecution(String taskName, String taskInstanceId) getExecutionsFailingLongerThan(Duration interval) voidgetScheduledExecutions(ScheduledExecutionsFilter filter, String taskName, Consumer<Execution> consumer) voidgetScheduledExecutions(ScheduledExecutionsFilter filter, Consumer<Execution> consumer) lockAndFetchGeneric(Instant now, int limit) lockAndGetDue(Instant now, int limit) voidintremoveExecutions(String taskName) replace(Execution toBeReplaced, SchedulableInstance<?> newInstance) Deprecated.replace(Execution toBeReplaced, ScheduledTaskInstance newInstance) booleanreschedule(Execution execution, Instant nextExecutionTime, Object newData, Instant lastSuccess, Instant lastFailure, int consecutiveFailures) booleanreschedule(Execution execution, Instant nextExecutionTime, Instant lastSuccess, Instant lastFailure, int consecutiveFailures) booleanupdateHeartbeat(Execution execution, Instant heartbeatTime) booleanupdateHeartbeatWithRetry(Execution execution, Instant newHeartbeat, int tries) void
-
Method Details
-
createIfNotExists
Deprecated.Prefer ScheduledTaskInstance which has a fixed execution-time -
createIfNotExists
-
getDue
-
createBatch
-
replace
-
replace
Deprecated.Prefer ScheduledTaskInstance which has a fixed execution-time -
getScheduledExecutions
-
getScheduledExecutions
void getScheduledExecutions(ScheduledExecutionsFilter filter, String taskName, Consumer<Execution> consumer) -
lockAndFetchGeneric
-
lockAndGetDue
-
remove
-
reschedule
-
reschedule
-
pick
-
getDeadExecutions
-
updateHeartbeatWithRetry
-
updateHeartbeat
-
getExecutionsFailingLongerThan
-
getExecution
-
getExecution
-
removeExecutions
-
verifySupportsLockAndFetch
void verifySupportsLockAndFetch()
-