Class WorkerResource

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      javax.ws.rs.core.Response getStepsList()
      Get a list of running steps
      javax.ws.rs.core.Response getStepStatus​(java.lang.String idAsync)
      Get the status of a step
      javax.ws.rs.core.Response modifyStep​(java.lang.String idAsync)
      Modifying a step (pausing, resuming, prioritizing)
      javax.ws.rs.core.Response submitStep​(javax.ws.rs.core.HttpHeaders headers, com.fasterxml.jackson.databind.JsonNode descriptionStepJson)
      Submit a step to be launched
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • WORKER_FACTORY

        public final WorkerFactory WORKER_FACTORY
        the worker factory
    • Constructor Detail

      • WorkerResource

        public WorkerResource​(PluginLoader pluginLoader)
        Constructor
        Parameters:
        pluginLoader - the plugin loader
    • Method Detail

      • getStepsList

        @Path("tasks")
        @GET
        @Produces("application/json")
        @Consumes("application/json")
        public javax.ws.rs.core.Response getStepsList()
        Get a list of running steps
        Returns:
        Response containing the list of steps
      • submitStep

        @Path("tasks")
        @POST
        @Produces("application/json")
        @Consumes("application/json")
        public javax.ws.rs.core.Response submitStep​(@Context
                                                    javax.ws.rs.core.HttpHeaders headers,
                                                    com.fasterxml.jackson.databind.JsonNode descriptionStepJson)
        Submit a step to be launched
        Parameters:
        headers - http header
        descriptionStepJson - the description of the step as a {fr.gouv.vitam.worker.common.DescriptionStep}
        Returns:
        Response containing the status of the step
      • getStepStatus

        @Path("tasks/{id_async}")
        @GET
        @Produces("application/json")
        public javax.ws.rs.core.Response getStepStatus​(@PathParam("id_async")
                                                       java.lang.String idAsync)
        Get the status of a step
        Parameters:
        idAsync - the id of the Async
        Returns:
        Response containing the status of a specific step
      • modifyStep

        @Path("tasks/{id_async}")
        @PUT
        @Produces("application/json")
        @Consumes("application/json")
        public javax.ws.rs.core.Response modifyStep​(@PathParam("id_async")
                                                    java.lang.String idAsync)
        Modifying a step (pausing, resuming, prioritizing)
        Parameters:
        idAsync - the id of the Async
        Returns:
        Response containing the status of the step