aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xsrc/main/java/org/onap/music/datastore/MusicDataStore.java3
-rw-r--r--src/main/java/org/onap/music/eelf/logging/MusicLoggingServletFilter.java2
-rw-r--r--src/main/java/org/onap/music/lockingservice/cassandra/CassaLockStore.java3
-rwxr-xr-xsrc/main/java/org/onap/music/main/MusicUtil.java10
-rw-r--r--src/main/java/org/onap/music/rest/RestMusicLocksAPI.java4
5 files changed, 10 insertions, 12 deletions
diff --git a/src/main/java/org/onap/music/datastore/MusicDataStore.java b/src/main/java/org/onap/music/datastore/MusicDataStore.java
index e3d4c780..6555ea21 100755
--- a/src/main/java/org/onap/music/datastore/MusicDataStore.java
+++ b/src/main/java/org/onap/music/datastore/MusicDataStore.java
@@ -284,8 +284,7 @@ public class MusicDataStore {
* @return TableMetadata
*/
public KeyspaceMetadata returnKeyspaceMetadata(String keyspace) {
- KeyspaceMetadata ks = cluster.getMetadata().getKeyspace(keyspace);
- return ks;
+ return cluster.getMetadata().getKeyspace(keyspace);
}
diff --git a/src/main/java/org/onap/music/eelf/logging/MusicLoggingServletFilter.java b/src/main/java/org/onap/music/eelf/logging/MusicLoggingServletFilter.java
index 1cac7737..c8c6ba65 100644
--- a/src/main/java/org/onap/music/eelf/logging/MusicLoggingServletFilter.java
+++ b/src/main/java/org/onap/music/eelf/logging/MusicLoggingServletFilter.java
@@ -172,7 +172,7 @@ public class MusicLoggingServletFilter implements Filter {
}
private void populateMDCAndResponseHeader(Map<String, String> headerMap, String idKey, String mdcKey,
- boolean isRequired, HttpServletResponse httpResponse) throws IOException {
+ boolean isRequired, HttpServletResponse httpResponse) {
idKey = idKey.trim().toUpperCase();
diff --git a/src/main/java/org/onap/music/lockingservice/cassandra/CassaLockStore.java b/src/main/java/org/onap/music/lockingservice/cassandra/CassaLockStore.java
index f57ecb6e..0ec85077 100644
--- a/src/main/java/org/onap/music/lockingservice/cassandra/CassaLockStore.java
+++ b/src/main/java/org/onap/music/lockingservice/cassandra/CassaLockStore.java
@@ -454,8 +454,7 @@ public class CassaLockStore {
}
- public void updateLockAcquireTime(String keyspace, String table, String key, String lockReference)
- throws MusicServiceException, MusicQueryException {
+ public void updateLockAcquireTime(String keyspace, String table, String key, String lockReference) {
table = table_prepend_name + table;
PreparedQueryObject queryObject = new PreparedQueryObject();
Long lockReferenceL = Long.parseLong(lockReference);
diff --git a/src/main/java/org/onap/music/main/MusicUtil.java b/src/main/java/org/onap/music/main/MusicUtil.java
index 21e5c255..d46e770e 100755
--- a/src/main/java/org/onap/music/main/MusicUtil.java
+++ b/src/main/java/org/onap/music/main/MusicUtil.java
@@ -4,7 +4,7 @@
* ===================================================================
* Copyright (c) 2017 AT&T Intellectual Property
* ===================================================================
- * Modifications Copyright (c) 2018 IBM.
+ * Modifications Copyright (c) 2019 IBM.
* Modifications Copyright (c) 2019 Samsung.
* ===================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
@@ -158,7 +158,10 @@ public class MusicUtil {
private static Boolean messageIdRequired = false;
private static String cipherEncKey = "";
-
+ public MusicUtil() {
+ throw new IllegalStateException("Utility Class");
+ }
+
public static String getLockUsing() {
return lockUsing;
}
@@ -167,9 +170,6 @@ public class MusicUtil {
MusicUtil.lockUsing = lockUsing;
}
- public MusicUtil() {
- throw new IllegalStateException("Utility Class");
- }
/**
*
* @return cassandra port
diff --git a/src/main/java/org/onap/music/rest/RestMusicLocksAPI.java b/src/main/java/org/onap/music/rest/RestMusicLocksAPI.java
index c08fc5d8..b839c7f2 100644
--- a/src/main/java/org/onap/music/rest/RestMusicLocksAPI.java
+++ b/src/main/java/org/onap/music/rest/RestMusicLocksAPI.java
@@ -358,7 +358,7 @@ public class RestMusicLocksAPI {
@ApiParam(value = "Authorization", required = true) @HeaderParam(MusicUtil.AUTHORIZATION) String authorization,
@ApiParam(value = "AID", required = false, hidden = true) @HeaderParam("aid") String aid,
@ApiParam(value = "Application namespace",
- required = false, hidden = true) @HeaderParam("ns") String ns) throws Exception{
+ required = false, hidden = true) @HeaderParam("ns") String ns) {
try {
ResponseBuilder response = MusicUtil.buildVersionResponse(VERSION, minorVersion, patchVersion);
Map<String, Object> resultMap = MusicCore.validateLock(lockName);
@@ -418,7 +418,7 @@ public class RestMusicLocksAPI {
@ApiParam(value = "Authorization", required = true) @HeaderParam(MusicUtil.AUTHORIZATION) String authorization,
@ApiParam(value = "AID", required = false, hidden = true) @HeaderParam("aid") String aid,
@ApiParam(value = "Application namespace",
- required = false, hidden = true) @HeaderParam("ns") String ns) throws Exception{
+ required = false, hidden = true) @HeaderParam("ns") String ns) {
try {
ResponseBuilder response = MusicUtil.buildVersionResponse(VERSION, minorVersion, patchVersion);
Map<String, Object> resultMap = MusicCore.validateLock(lockName);