Source:
public Response saveContainerSpec(@Context HttpHeaders headers, @ApiParam(name = "serverTemplateId", value = "ID of the KIE Server template associated with the new KIE container", required = true) @PathParam("serverTemplateId") String serverTemplateId, @ApiParam(name = "containerId", value = "ID of the new KIE container", required = true) @PathParam("containerId") String containerId, @ApiParam(name = "body", value = "A map containing the container-name, relevant release-id (group ID, artifact ID, and version), configuration specifications (rule, process, planning), and other components of the new KIE container", required = true, examples = @Example(value = { @ExampleProperty(mediaType = JSON, value = CONTAINER_SPEC_JSON), @ExampleProperty(mediaType = XML, value = CONTAINER_SPEC_XML) })) String containerSpecPayload, @Context UriInfo uriInfo) { String contentType = getContentType(headers); try { logger.debug("Received save container spec request for server template with id {}", serverTemplateId); ContainerSpec containerSpec = unmarshal(containerSpecPayload, contentType, ContainerSpec.class); logger.debug("Container spec is {}", containerSpec); specManagementService.saveContainerSpec(serverTemplateId, containerSpec); logger.debug("Returning response for save container spec request for server template with id '{}': CREATED", serverTemplateId); String response = marshal(contentType, new ServiceResponse(KieServiceResponse.ResponseType.SUCCESS, "KIE container " + containerId + " successfully deployed")); return createCreatedVariant(response, headers, uriInfo.getAbsolutePathBuilder()); } catch (KieServerControllerIllegalArgumentException e) { return createCorrectVariant(e.getMessage(), headers, Response.Status.NOT_FOUND); } catch (KieServerControllerException e){ return createCorrectVariant(REQUEST_FAILED_TOBE_PROCESSED + e.getMessage(), headers, Response.Status.BAD_REQUEST); } catch (Exception e) { logger.error("Save container spec request for server template id failed due to {}", serverTemplateId, e.getMessage(), e); return createCorrectVariant("Unknown error " + e.getMessage(), headers, Response.Status.INTERNAL_SERVER_ERROR); } }

Target:
public Response saveContainerSpec(@Context HttpHeaders headers, @ApiParam(name = "serverTemplateId", value = "ID of the KIE Server template associated with the new KIE container", required = true) @PathParam("serverTemplateId") String serverTemplateId, @ApiParam(name = "containerId", value = "ID of the new KIE container", required = true) @PathParam("containerId") String containerId, @ApiParam(name = "body", value = "A map containing the container-name, relevant release-id (group ID, artifact ID, and version), configuration specifications (rule, process, planning), and other components of the new KIE container", required = true, examples = @Example(value = { @ExampleProperty(mediaType = JSON, value = CONTAINER_SPEC_JSON), @ExampleProperty(mediaType = XML, value = CONTAINER_SPEC_XML) })) String containerSpecPayload, @Context UriInfo uriInfo) { String contentType = getContentType(headers); try { logger.debug("Received save container spec request for server template with id {}", serverTemplateId); ContainerSpec containerSpec = unmarshal(containerSpecPayload, contentType, ContainerSpec.class); logger.debug("Container spec is {}", containerSpec); specManagementService.saveContainerSpec(serverTemplateId, containerSpec); logger.debug("Returning response for save container spec request for server template with id '{}': CREATED", serverTemplateId); return createCreatedVariant("", headers, uriInfo.getAbsolutePathBuilder()); } catch (KieServerControllerIllegalArgumentException e) { return createCorrectVariant(e.getMessage(), headers, Response.Status.NOT_FOUND); } catch (KieServerControllerException e){ return createCorrectVariant(REQUEST_FAILED_TOBE_PROCESSED + e.getMessage(), headers, Response.Status.BAD_REQUEST); } catch (Exception e) { logger.error("Save container spec request for server template id failed due to {}", serverTemplateId, e.getMessage(), e); return createCorrectVariant("Unknown error " + e.getMessage(), headers, Response.Status.INTERNAL_SERVER_ERROR); } }