Class LongTaskResource
- java.lang.Object
-
- com.atlassian.confluence.plugins.restapi.resources.LongTaskResource
-
public class LongTaskResource extends Object
REST wrapper for the LongTaskService.
-
-
Constructor Summary
Constructors Constructor Description LongTaskResource(LongTaskService longTaskService)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description LongTaskStatus
getTask(String idStr, String expand)
Returns information about a long-running task.RestList<LongTaskStatus>
getTasks(String expand, int start, int limit, javax.ws.rs.core.UriInfo uriInfo)
Returns information about all tracked long-running tasks.static javax.ws.rs.core.Response
submissionResponse(LongTaskSubmission taskSubmission)
Produce a HTTP Accept 202 response from some other resource pointing to this class's LongTaskStatus resource.
-
-
-
Constructor Detail
-
LongTaskResource
public LongTaskResource(LongTaskService longTaskService)
-
-
Method Detail
-
getTasks
public RestList<LongTaskStatus> getTasks(String expand, int start, int limit, @Context javax.ws.rs.core.UriInfo uriInfo)
Returns information about all tracked long-running tasks.
- Parameters:
expand
- a comma separated list of properties to expand on the tasks- Returns:
- a JSON representation of a list of tasks, may be empty.
- Throws:
ServiceException
-
getTask
@PublicApi public LongTaskStatus getTask(String idStr, String expand)
Returns information about a long-running task.
- Parameters:
idStr
- the key of the task to be returnedexpand
- a comma separated list of properties to expand on the task- Returns:
- a JSON representation of a long task, or a 404 if not found.
- Throws:
ServiceException
-
submissionResponse
public static javax.ws.rs.core.Response submissionResponse(LongTaskSubmission taskSubmission)
Produce a HTTP Accept 202 response from some other resource pointing to this class's LongTaskStatus resource.
-
-