diff options
author | Thomas Nelson Jr (arthurdent3) tn1381@att.com <tn1381@att.com> | 2018-03-04 03:28:07 -0500 |
---|---|---|
committer | Thomas Nelson Jr (arthurdent3) tn1381@att.com <tn1381@att.com> | 2018-03-04 03:28:07 -0500 |
commit | f327e0cb4a14ff8d4f85e5ae9da5986b8c87ab8c (patch) | |
tree | c5fc16c846c3e4b1c894c359e91cf68baa4af088 /src/main/java/org/onap/music/rest/RestMusicAdminAPI.java | |
parent | 168c54c6e774563910a3ed5a7480ea63cd3fe572 (diff) |
Sonar Fixes to increate Coverage on Unit tests
Including bug fix that added proper Exception handling on REST Calls.
Change-Id: I618faa69ab549e76c148bb7c664a5ffe0eae84ca
Issue-ID: MUSIC-44, MUSIC-45
Signed-off-by: Thomas Nelson Jr (arthurdent3) tn1381@att.com <tn1381@att.com>
Diffstat (limited to 'src/main/java/org/onap/music/rest/RestMusicAdminAPI.java')
-rwxr-xr-x | src/main/java/org/onap/music/rest/RestMusicAdminAPI.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/org/onap/music/rest/RestMusicAdminAPI.java b/src/main/java/org/onap/music/rest/RestMusicAdminAPI.java index 0265d039..6d8ac088 100755 --- a/src/main/java/org/onap/music/rest/RestMusicAdminAPI.java +++ b/src/main/java/org/onap/music/rest/RestMusicAdminAPI.java @@ -195,7 +195,7 @@ public class RestMusicAdminAPI { String ks = row.getString("keyspace_name"); if (!ks.equals(MusicUtil.DEFAULTKEYSPACENAME)) { PreparedQueryObject queryObject = new PreparedQueryObject(); - queryObject.appendQueryString("DROP KEYSPACE " + ks + ";"); + queryObject.appendQueryString("DROP KEYSPACE IF EXISTS " + ks + ";"); MusicCore.nonKeyRelatedPut(queryObject, consistency); } } |