aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/org/onap/music/rest/RestMusicQAPI.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/org/onap/music/rest/RestMusicQAPI.java')
-rwxr-xr-xsrc/main/java/org/onap/music/rest/RestMusicQAPI.java10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/main/java/org/onap/music/rest/RestMusicQAPI.java b/src/main/java/org/onap/music/rest/RestMusicQAPI.java
index 8af334c7..9248ee1a 100755
--- a/src/main/java/org/onap/music/rest/RestMusicQAPI.java
+++ b/src/main/java/org/onap/music/rest/RestMusicQAPI.java
@@ -45,14 +45,17 @@ import org.onap.music.eelf.logging.format.AppMessages;
import org.onap.music.eelf.logging.format.ErrorSeverity;
import org.onap.music.eelf.logging.format.ErrorTypes;
import org.apache.commons.lang3.StringUtils;
+import org.onap.music.datastore.MusicDataStoreHandle;
import org.onap.music.datastore.PreparedQueryObject;
import com.datastax.driver.core.ResultSet;
import org.onap.music.exceptions.MusicServiceException;
-import org.onap.music.main.MusicCore;
import org.onap.music.main.MusicUtil;
import org.onap.music.main.ResultType;
// cjc import org.onap.music.main.ReturnType;
import org.onap.music.response.jsonobjects.JsonResponse;
+import org.onap.music.service.MusicCoreService;
+import org.onap.music.service.impl.MusicCassaCore;
+
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
@@ -64,6 +67,7 @@ import io.swagger.annotations.ApiParam;
public class RestMusicQAPI {
private EELFLoggerDelegate logger = EELFLoggerDelegate.getLogger(RestMusicQAPI.class);
+ private static MusicCoreService musicCore = MusicCassaCore.getInstance();
// private static String xLatestVersion = "X-latestVersion";
/*
* private EELFLoggerDelegate logger = EELFLoggerDelegate.getLogger(RestMusicDataAPI.class);
@@ -412,9 +416,9 @@ public class RestMusicQAPI {
}
try {
- ResultSet results = MusicCore.get(queryObject);
+ ResultSet results = musicCore.get(queryObject);
return response.status(Status.OK).entity(new JsonResponse(ResultType.SUCCESS)
- .setDataResult(MusicCore.marshallResults(results)).toMap()).build();
+ .setDataResult(MusicDataStoreHandle.marshallResults(results)).toMap()).build();
} catch (MusicServiceException ex) {
logger.error(EELFLoggerDelegate.errorLogger, "", AppMessages.UNKNOWNERROR,
ErrorSeverity.ERROR, ErrorTypes.MUSICSERVICEERROR);