TaskActivityService¶
-
public interface
TaskActivityService
¶ Service for managing task activities. Task activities are used for storing information about past task executions.
Methods¶
addError¶
-
void
addError
(Task task, TaskHandlerException e)¶ Logs an execution error for the given task.
Parameters: - task – the failed task, not null
- e – the cause of the error, not null
addSuccess¶
addWarning¶
addWarning¶
addWarning¶
deleteActivitiesForTask¶
getLatestActivities¶
-
List<TaskActivity>
getLatestActivities
()¶ Returns 10 most recent activities as a list, ordered by date.
Returns: the list of all activities
getTaskActivities¶
-
List<TaskActivity>
getTaskActivities
(Long taskId, Set<TaskActivityType> activityTypeSet, QueryParams queryParams)¶ Returns list of all activities for task with the given ID.
Parameters: - taskId – the task ID, null returns null
- activityTypeSet – the type of activities
- queryParams – query parameters to use while retrieving
Returns: the list of all activities for task with given ID
getTaskActivitiesCount¶
-
long
getTaskActivitiesCount
(Long taskId, Set<TaskActivityType> activityTypes)¶ Returns the count of all activities for the given task, of the specified type.
Parameters: - taskId – the task ID
- activityTypes – the type of activities to include in count
Returns: the count of matching activities
getTaskActivitiesCount¶
-
long
getTaskActivitiesCount
(Long taskId, TaskActivityType type)¶ Returns the count of all activities for the given task, of the specified type.
Parameters: - taskId – the task ID
- type – the type of activity to include in count
Returns: the count of matching activities