Interface TaskService


@Deprecated @Path("/task") @Consumes({"application/xml","application/json"}) @Produces({"application/xml","application/json"}) public interface TaskService
Deprecated.
Use TaskBlockService instead.
Manages tasks on the XL Deploy Server.
  • Method Details

    • getMyCurrentTasks

      @GET @Path("current") List<TaskState> getMyCurrentTasks()
      Deprecated.
      Returns the active tasks of the logged in user.
      Returns:
      a list of tasks.
    • getAllCurrentTasks

      @GET @Path("current/all") List<TaskState> getAllCurrentTasks()
      Deprecated.
      Returns all active tasks for all users. Only allowed for admin.
      Returns:
      a list of tasks.
    • getTask

      @GET @Path("{taskid}") TaskState getTask(@PathParam("taskid") String taskId)
      Deprecated.
      Returns a task by ID.
      Parameters:
      taskId - the ID of the task
      Returns:
      the task.
      Permission:
      Available only to admin and owner of the task
    • getSteps

      @GET @Path("{taskid}/step") TaskWithSteps getSteps(@PathParam("taskid") String taskId)
      Deprecated.
      Returns a task containing step information.
      Parameters:
      taskId - the ID of the task
      Returns:
      a task with full step information.
      Permission:
      Available only to admin and owner of the task
    • getStep

      @GET @Path("{taskid}/step/{stepId}") StepState getStep(@PathParam("taskid") String taskId, @PathParam("stepId") int stepId, @HeaderParam("If-Modified-Since") org.joda.time.DateTime ifModifiedSince)
      Deprecated.
      Retrieves information about a step.
      Parameters:
      taskId - the ID of the task
      stepId - the ordinal number of the step, starting from 1
      ifModifiedSince - the if-modified-since date in RFC 1123 (RFC 822 with 4-digit years) date format.
      Returns:
      a stepStep
      RestDetails:
      If the step has not been modified since ifModifiedSince, a response with status code of 304 (Not Modified), otherwise returns a response with a status code of 200 (OK) and XML containing a StepState.
      Permission:
      Available only to admin and owner of the task
      ApiDetails:
      If the step has not been modified since ifModifiedSince, the method throws a RuntimeException, otherwise returns a StepState
    • start

      @POST @Path("{taskid}/start") void start(@PathParam("taskid") String taskId)
      Deprecated.
      Starts a task.
      Parameters:
      taskId - the ID of the task
      Permission:
      Available only to admin and owner of the task
    • schedule

      @POST @Path("{taskid}/schedule") void schedule(@PathParam("taskid") String taskId, @QueryParam("time") org.joda.time.DateTime time)
      Deprecated.
      Schedules a task.
      Parameters:
      taskId - the ID of the task
      time - the local time (including the local timezone) when the task should be started by the server.
      Permission:
      Available only to admin and owner of the task
    • stop

      @POST @Path("{taskid}/stop") void stop(@PathParam("taskid") String taskId)
      Deprecated.
      Gracefully stops an active task.
      Parameters:
      taskId - the ID of the task
      Permission:
      Available only to admin and owner of the task
    • abort

      @POST @Path("{taskid}/abort") void abort(@PathParam("taskid") String taskId)
      Deprecated.
      Aborts an active task.
      Parameters:
      taskId - the ID of the task
      Permission:
      Available only to admin and owner of the task
    • cancel

      @DELETE @Path("{taskid}") void cancel(@PathParam("taskid") String taskId)
      Deprecated.
      Cancels a stopped task.
      Parameters:
      taskId - the ID of the task
      Permission:
      Available only to admin and owner of the task
    • archive

      @POST @Path("{taskid}/archive") void archive(@PathParam("taskid") String taskId)
      Deprecated.
      Archive an executed task.
      Parameters:
      taskId - the ID of the task
      Permission:
      Available only to admin and owner of the task
    • skip

      @POST @Path("{taskid}/skip") TaskWithSteps skip(@PathParam("taskid") String taskId, List<Integer> stepIds)
      Deprecated.
      Indicates that one or more steps should be skipped.
      Parameters:
      taskId - the ID of the task
      stepIds - the IDs of the steps to skip
      Returns:
      a task with full step information.
      Permission:
      task#skip_step
    • unskip

      @POST @Path("{taskid}/unskip") TaskWithSteps unskip(@PathParam("taskid") String taskId, List<Integer> stepIds)
      Deprecated.
      Indicates that one or more steps should no longer be skipped, but executed.
      Parameters:
      taskId - the ID of the task
      stepIds - the IDs of the steps to unskip
      Returns:
      a task with full step information.
      Permission:
      task#skip_step
    • addPause

      @POST @Path("{taskid}/pause/{stepId}") TaskWithSteps addPause(@PathParam("taskid") String taskId, @PathParam("stepId") int stepId)
      Deprecated.
      Add a pause step at the specified position.
      Parameters:
      taskId - the ID of the task
      stepId - the position of the step in the step list.
      Returns:
      a task with full step information.
      Permission:
      Available only to admin and owner of the task
    • assign

      @POST @Path("{taskid}/assign/{owner}") TaskState assign(@PathParam("taskid") String taskId, @PathParam("owner") String owner)
      Deprecated.
      Assigns a task to a different user.
      Parameters:
      taskId - the ID of the task
      owner - the name of the user that will be the new owner of the task.
      Returns:
      the task.
      Permission:
      task#assign
    • takeover

      @POST @Path("{taskid}/takeover/{owner}") TaskState takeover(@PathParam("taskid") String taskId, @PathParam("owner") String owner)
      Deprecated.
      Takeover a task from the owner. This will re-assign the task to your logged in user. This is the reverse of the assign(String, String) method, which allows you to re-assign a task.
      Parameters:
      taskId - the ID of the task to take over
      owner - the current owner of the task
      Returns:
      the task you took over.
      Permission:
      task#takeover
    • query

      @GET @Path("query") Stream<TaskState> query(@QueryParam("begindate") org.joda.time.LocalDate begin, @QueryParam("enddate") org.joda.time.LocalDate end)
      Deprecated.
      Searches for archived tasks without step information.
      Parameters:
      begin - The first day we want to see tasks from, or null for no such limit.
      end - The last day we want to see tasks from, or null for no such limit.
      Returns:
      a list of tasks.
      Permission:
      report#view
    • export

      @GET @Path("export") Stream<TaskWithSteps> export(@QueryParam("begindate") org.joda.time.LocalDate begin, @QueryParam("enddate") org.joda.time.LocalDate end)
      Deprecated.
      Searches for tasks with detailed step information.
      Parameters:
      begin - The first day we want to see tasks from, or null for no such limit.
      end - The last day we want to see tasks from, or null for no such limit.
      Returns:
      a list of tasks with step information.
      Permission:
      report#view