Class PipelineResource


  • @RestController
    @RequestMapping("/api")
    public class PipelineResource
    extends Object
    REST controller for managing Pipeline.
    • Constructor Detail

      • PipelineResource

        public PipelineResource​(PipelineService pipelineService)
    • Method Detail

      • createPipeline

        @PostMapping("/pipelines")
        public org.springframework.http.ResponseEntity<Pipeline> createPipeline​(@Valid @RequestBody
                                                                                @Valid Pipeline pipeline)
                                                                         throws URISyntaxException
        POST /pipelines : Create a new pipeline.
        Parameters:
        pipeline - the pipeline to create.
        Returns:
        the ResponseEntity with status 201 (Created) and with body the new pipeline, or with status 400 (Bad Request) if the pipeline has already an ID.
        Throws:
        URISyntaxException - if the Location URI syntax is incorrect.
      • updatePipeline

        @PutMapping("/pipelines")
        public org.springframework.http.ResponseEntity<Pipeline> updatePipeline​(@Valid @RequestBody
                                                                                @Valid Pipeline pipeline)
                                                                         throws URISyntaxException
        PUT /pipelines : Updates an existing pipeline.
        Parameters:
        pipeline - the pipeline to update.
        Returns:
        the ResponseEntity with status 200 (OK) and with body the updated pipeline, or with status 400 (Bad Request) if the pipeline is not valid, or with status 500 (Internal Server Error) if the pipeline couldn't be updated.
        Throws:
        URISyntaxException - if the Location URI syntax is incorrect.
      • getAllPipelines

        @GetMapping("/pipelines")
        public List<Pipeline> getAllPipelines()
        GET /pipelines : get all the pipelines.
        Returns:
        the ResponseEntity with status 200 (OK) and the list of pipelines in body.
      • getPipeline

        @GetMapping("/pipelines/{id}")
        public org.springframework.http.ResponseEntity<Pipeline> getPipeline​(@PathVariable
                                                                             Long id)
        GET /pipelines/:id : get the "id" pipeline.
        Parameters:
        id - the id of the pipeline to retrieve.
        Returns:
        the ResponseEntity with status 200 (OK) and with body the pipeline, or with status 404 (Not Found).
      • deletePipeline

        @DeleteMapping("/pipelines/{id}")
        public org.springframework.http.ResponseEntity<Void> deletePipeline​(@PathVariable
                                                                            Long id)
        DELETE /pipelines/:id : delete the "id" pipeline.
        Parameters:
        id - the id of the pipeline to delete.
        Returns:
        the ResponseEntity with status 204 (NO_CONTENT).