diff options
author | wasala <przemyslaw.wasala@nokia.com> | 2018-05-10 13:08:00 +0200 |
---|---|---|
committer | wasala <przemyslaw.wasala@nokia.com> | 2018-05-10 13:32:17 +0200 |
commit | 8c88efe7a0abe051e8a4c4d271c84eb8e68c29f0 (patch) | |
tree | 073e23915e20e3bff2717cde0d76913d58ce7e82 /prh-dmaap-client | |
parent | 44ce56cf2e6bfae17c443901ac6ded8ba8cdd414 (diff) |
Added DmaapProducer in task workflow scheduler
Change-Id: I46c8ff37ca758525e6647d5057d50595f5739208
Issue-ID: DCAEGEN2-474
Signed-off-by: wasala <przemyslaw.wasala@nokia.com>
Diffstat (limited to 'prh-dmaap-client')
2 files changed, 6 insertions, 7 deletions
diff --git a/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/config/DmaapPublisherConfiguration.java b/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/config/DmaapPublisherConfiguration.java index ac26ea97..6f5f17c4 100644 --- a/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/config/DmaapPublisherConfiguration.java +++ b/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/config/DmaapPublisherConfiguration.java @@ -21,7 +21,6 @@ package org.onap.dcaegen2.services.config; import org.immutables.gson.Gson; import org.immutables.value.Value; -import org.springframework.stereotype.Component; /** * @author <a href="mailto:przemyslaw.wasala@nokia.com">Przemysław Wąsala</a> on 3/23/18 diff --git a/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/service/producer/ExtendedDmaapProducerHttpClientImpl.java b/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/service/producer/ExtendedDmaapProducerHttpClientImpl.java index af7534c6..98c9a83e 100644 --- a/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/service/producer/ExtendedDmaapProducerHttpClientImpl.java +++ b/prh-dmaap-client/src/main/java/org/onap/dcaegen2/services/service/producer/ExtendedDmaapProducerHttpClientImpl.java @@ -69,7 +69,7 @@ public class ExtendedDmaapProducerHttpClientImpl { try { extendedDetails = closeableHttpClient.execute(request.get(), dmaapProducerResponseHandler()); } catch (IOException | NullPointerException e) { - logger.error("Exception while executing HTTP request: {}", e); + logger.warn("Exception while executing HTTP request: ", e); } return extendedDetails; @@ -85,7 +85,7 @@ public class ExtendedDmaapProducerHttpClientImpl { try { stringEntity = Optional.of(new StringEntity(jsonBody.get())); } catch (UnsupportedEncodingException e) { - logger.error("Exception while parsing JSON: {}", e); + logger.warn("Exception while parsing JSON: ", e); } return stringEntity; @@ -115,9 +115,9 @@ public class ExtendedDmaapProducerHttpClientImpl { try { extendedURI = uriBuilder.build(); - logger.info("Building extended URI: {}", extendedURI); + logger.trace("Building extended URI: {}", extendedURI); } catch (URISyntaxException e) { - logger.error("Exception while building extended URI: ", e); + logger.warn("Exception while building extended URI: ", e); } return extendedURI; @@ -144,11 +144,11 @@ public class ExtendedDmaapProducerHttpClientImpl { final HttpEntity responseEntity = httpResponse.getEntity(); if (HttpUtils.isSuccessfulResponseCode(responseCode)) { - logger.info("HTTP response successful."); + logger.trace("HTTP response successful."); return Optional.of("" + responseCode); } else { String response = responseEntity != null ? EntityUtils.toString(responseEntity) : ""; - logger.error("HTTP response not successful : {}", response); + logger.warn("HTTP response not successful : {}", response); return Optional.of("" + responseCode); } }; |