X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=cps-ncmp-service%2Fsrc%2Fmain%2Fjava%2Forg%2Fonap%2Fcps%2Fncmp%2Fapi%2Fimpl%2Fclient%2FDmiRestClient.java;h=94faa557fa3dd90f10ffb000b2d70391072f84b8;hb=82ebf531110deba98086f8f7cb9c745519bbc4f4;hp=9f3df6b9a5d9bc74bcad868260f43176b9b2e59a;hpb=4207fab422760b17187d37776ebc1867b995bba1;p=cps.git diff --git a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/client/DmiRestClient.java b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/client/DmiRestClient.java index 9f3df6b9a..94faa557f 100644 --- a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/client/DmiRestClient.java +++ b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/client/DmiRestClient.java @@ -53,11 +53,11 @@ public class DmiRestClient { * @param httpHeaders http headers * @return response entity of type String */ - public ResponseEntity postOperationWithJsonData(final String dmiResourceUrl, + public ResponseEntity postOperationWithJsonData(final String dmiResourceUrl, final String jsonData, final HttpHeaders httpHeaders) { final var httpEntity = new HttpEntity<>(jsonData, configureHttpHeaders(httpHeaders)); - return restTemplate.postForEntity(dmiResourceUrl, httpEntity, String.class); + return restTemplate.postForEntity(dmiResourceUrl, httpEntity, Object.class); } private HttpHeaders configureHttpHeaders(final HttpHeaders httpHeaders) { @@ -72,8 +72,8 @@ public class DmiRestClient { * @param httpHeaders http headers * @return response entity of type String */ - public ResponseEntity postOperation(final String dmiResourceUrl, final HttpHeaders httpHeaders) { + public ResponseEntity postOperation(final String dmiResourceUrl, final HttpHeaders httpHeaders) { final var httpEntity = new HttpEntity<>(configureHttpHeaders(httpHeaders)); - return restTemplate.exchange(dmiResourceUrl, HttpMethod.POST, httpEntity, String.class); + return restTemplate.exchange(dmiResourceUrl, HttpMethod.POST, httpEntity, Object.class); } }