Class TaskAdminController

java.lang.Object
org.tailormap.api.controller.admin.TaskAdminController

@RestController public class TaskAdminController extends Object
Admin controller for controlling the task scheduler. Not to be used to create new tasks, adding tasks belongs in the domain of the specific controller or Spring Data REST API as that requires specific configuration information.
  • Constructor Details

    • TaskAdminController

      public TaskAdminController(org.quartz.Scheduler scheduler)
  • Method Details

    • list

      @GetMapping(path="${tailormap-api.admin.base-path}/tasks", produces="application/json") public org.springframework.http.ResponseEntity<?> list(@RequestParam(required=false) String type) throws org.quartz.SchedulerException
      Throws:
      org.quartz.SchedulerException
    • details

      @GetMapping(path="${tailormap-api.admin.base-path}/tasks/{type}/{uuid}", produces="application/json") public org.springframework.http.ResponseEntity<?> details(@PathVariable String type, @PathVariable UUID uuid) throws org.quartz.SchedulerException
      Throws:
      org.quartz.SchedulerException
    • startTask

      @PutMapping(path="${tailormap-api.admin.base-path}/tasks/{type}/{uuid}/start", produces="application/json") public org.springframework.http.ResponseEntity<?> startTask(@PathVariable String type, @PathVariable UUID uuid)
    • stopTask

      @PutMapping(path="${tailormap-api.admin.base-path}/tasks/{type}/{uuid}/stop", produces="application/json") public org.springframework.http.ResponseEntity<?> stopTask(@PathVariable String type, @PathVariable UUID uuid)
    • delete

      @DeleteMapping(path="${tailormap-api.admin.base-path}/tasks/{type}/{uuid}", produces="application/json") public org.springframework.http.ResponseEntity<?> delete(@PathVariable String type, @PathVariable UUID uuid) throws org.quartz.SchedulerException
      Throws:
      org.quartz.SchedulerException