| Package | Description |
|---|---|
| com.spikeify.taskqueue.entities | |
| com.spikeify.taskqueue.service |
| Modifier and Type | Field and Description |
|---|---|
protected TaskState |
QueueTask.state
internal task state ...
|
| Modifier and Type | Field and Description |
|---|---|
protected HashMap<TaskState,String> |
QueueInfo.statistics
JSON serialized map of statistics data
TaskState TaskStatistics |
| Modifier and Type | Method and Description |
|---|---|
TaskState |
QueueTask.getState() |
static TaskState |
TaskState.valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static TaskState[] |
TaskState.values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
TaskState.canTransition(TaskState toState) |
static String |
QueueTask.getStateFilter(String queueName,
TaskState taskState)
Utility method to get correct filter for equals filtering searching for task state
|
TaskStatistics |
QueueInfo.getStatistics(TaskState state) |
void |
QueueTask.setState(TaskState newState)
Change the tasks state when started, failed of finished
|
void |
QueueInfo.setStatistics(TaskState state,
TaskStatistics output) |
| Modifier and Type | Method and Description |
|---|---|
List<QueueTask> |
TaskQueueService.list(TaskState state,
String queueName)
Lists all tasks from queue in given state
|
List<QueueTask> |
DefaultTaskQueueService.list(TaskState state,
String queueName) |
TaskStatistics |
TaskQueueService.purge(TaskState state,
int taskAge,
String queueName)
Removes tasks from queue
|
TaskStatistics |
DefaultTaskQueueService.purge(TaskState state,
int taskAge,
String queueName) |
QueueTask |
TaskQueueService.transition(QueueTask task,
TaskState state)
Transitions job from current state to new state
This is done in transaction so only one thread can change the state (this is then the worker thread for this job)
|
QueueTask |
DefaultTaskQueueService.transition(QueueTask task,
TaskState newState) |
Copyright © 2015. All rights reserved.