summaryrefslogtreecommitdiffstats
path: root/src/main
diff options
context:
space:
mode:
authorSurendra Reddy Katam <SK00524980@techmahindra.com>2018-04-13 11:50:46 +0530
committerSurendra Reddy Katam <SK00524980@techmahindra.com>2018-04-13 11:50:46 +0530
commit64eeeab7b448217ca063449fc32013bb46ce1515 (patch)
tree318d520aae7b60b0bd8f6aaa3868bf0d7a525445 /src/main
parent42c9d364677967d0e4db72898457197399f3d9e5 (diff)
Sonar critical issues
Either log or rethrow this exception Sonar Link: https://sonar.onap.org/project/issues?assignees=surendraReddy&id=org.onap.dmaap.messagerouter.msgrtr%3Amsgrtr&open=AV4-Vahb32hFUzlqc5uD&resolved=false&severities=CRITICAL Location: src/main/java/com/att/nsa/cambria/resources/streamReaders/CambriaJsonStreamReader.java Line No-111 Change-Id: I98b083ebc2410e3da5a15d52d4917311b33d10f7 Issue-ID: DMAAP-408 Signed-off-by: Surendra Reddy Katam <SK00524980@techmahindra.com>
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/com/att/nsa/cambria/resources/streamReaders/CambriaJsonStreamReader.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main/java/com/att/nsa/cambria/resources/streamReaders/CambriaJsonStreamReader.java b/src/main/java/com/att/nsa/cambria/resources/streamReaders/CambriaJsonStreamReader.java
index 9d727ad..54a9bc6 100644
--- a/src/main/java/com/att/nsa/cambria/resources/streamReaders/CambriaJsonStreamReader.java
+++ b/src/main/java/com/att/nsa/cambria/resources/streamReaders/CambriaJsonStreamReader.java
@@ -22,6 +22,7 @@
package com.att.nsa.cambria.resources.streamReaders;
import java.io.InputStream;
+import java.util.logging.Logger;
import javax.servlet.http.HttpServletResponse;
@@ -34,14 +35,17 @@ import com.att.nsa.cambria.backends.Publisher.message;
import com.att.nsa.cambria.beans.LogDetails;
import com.att.nsa.cambria.resources.CambriaEventSet.reader;
+import jline.internal.Log;
+
/**
*
* @author author
*
*/
public class CambriaJsonStreamReader implements reader {
+ private static final Logger LOG = Logger.getLogger(CambriaJsonStreamReader.class.toString());
private final JSONTokener fTokens;
- private final boolean fIsList;
+ private final boolean fIsList;
private long fCount;
private final String fDefPart;
public static final String kKeyField = "cambria.partition";
@@ -109,6 +113,7 @@ public class CambriaJsonStreamReader implements reader {
fCount++;
return new msg(o);
} catch (JSONException e) {
+ Log.error(e.toString());
throw new CambriaApiException(HttpServletResponse.SC_BAD_REQUEST, e.getMessage());
}