diff options
author | Kishore Reddy, Gujja (kg811t) <kg811t@research.att.com> | 2018-05-14 15:32:13 -0400 |
---|---|---|
committer | Kishore Reddy, Gujja (kg811t) <kg811t@research.att.com> | 2018-05-14 15:32:13 -0400 |
commit | 8ee3ed5bafb8e6ff520869a05432fc19b696e339 (patch) | |
tree | 0db06c968376691e217f149382101a718cad9d28 /ecomp-sdk/epsdk-music/src | |
parent | fe25bf3a040455e931a9f5f61ff913ce78db1d69 (diff) |
File changes
Issue-ID: PORTAL-210
Included the music service changes.
Change-Id: Iacb401932ad9848eb2d53a1821d0674a1bfe9c61
Signed-off-by: Kishore Reddy, Gujja (kg811t) <kg811t@research.att.com>
Diffstat (limited to 'ecomp-sdk/epsdk-music/src')
-rw-r--r-- | ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/conf/MusicSession.java | 2 | ||||
-rw-r--r-- | ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/service/MusicService.java | 20 |
2 files changed, 11 insertions, 11 deletions
diff --git a/ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/conf/MusicSession.java b/ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/conf/MusicSession.java index f1defe3c..245e8d14 100644 --- a/ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/conf/MusicSession.java +++ b/ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/conf/MusicSession.java @@ -375,7 +375,7 @@ public final class MusicSession implements Session, Serializable { } private static String generateId() { - return UUID.randomUUID().toString(); + return UUID.randomUUID().toString().replaceAll("-", "~"); } private static final long serialVersionUID = 7160779239673823561L; diff --git a/ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/service/MusicService.java b/ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/service/MusicService.java index 801e9c03..3861b2dd 100644 --- a/ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/service/MusicService.java +++ b/ecomp-sdk/epsdk-music/src/main/java/org/onap/portalapp/music/service/MusicService.java @@ -112,7 +112,7 @@ public class MusicService { } if (isAtomicPut) - result = MusicCore.atomicPut(musicKeySpace, tableName, sessionId, queryObject, null); + result = MusicCore.atomicPutWithDeleteLock(musicKeySpace, tableName, sessionId, queryObject, null); else result = MusicCore.eventualPut(queryObject); logger.debug(EELFLoggerDelegate.debugLogger, "setAttribute: attributeName: " + attributeName @@ -144,7 +144,7 @@ public class MusicService { queryObject.addValue(String.valueOf(session.getMaxInactiveInterval())); queryObject.addValue(session.getId()); if (isAtomicPut) - result = MusicCore.atomicPut(musicKeySpace, musicMetaTable, session.getId(), queryObject, null); + result = MusicCore.atomicPutWithDeleteLock(musicKeySpace, musicMetaTable, session.getId(), queryObject, null); else result = MusicCore.eventualPut(queryObject); logger.debug(EELFLoggerDelegate.debugLogger, @@ -170,7 +170,7 @@ public class MusicService { queryObject.appendQueryString(querySB.toString()); queryObject.addValue(sessionId); if (isAtomicGet) - result = MusicCore.atomicGet(musicKeySpace, musicMetaTable, sessionId, queryObject); + result = MusicCore.atomicGetWithDeleteLock(musicKeySpace, musicMetaTable, sessionId, queryObject); else result = MusicCore.get(queryObject); logger.debug(EELFLoggerDelegate.debugLogger, "getMetaAttribute: with session id: " + sessionId); @@ -226,7 +226,7 @@ public class MusicService { queryObject.appendQueryString(querySB.toString()); if (isAtomicGet) - result = MusicCore.atomicGet(musicKeySpace, tableName, sessionId, queryObject); + result = MusicCore.atomicGetWithDeleteLock(musicKeySpace, tableName, sessionId, queryObject); else result = MusicCore.get(queryObject); return MusicUtil.musicRestResponseDataParsing(result, attributeName); @@ -262,7 +262,7 @@ public class MusicService { tableName = musicMetaTable; queryObject.appendQueryString(querySB.toString()); if (isAtomicPut) - result = MusicCore.atomicPut(musicKeySpace, tableName, sessionId, queryObject, null); + result = MusicCore.atomicPutWithDeleteLock(musicKeySpace, tableName, sessionId, queryObject, null); else result = MusicCore.eventualPut(queryObject); logger.debug(EELFLoggerDelegate.debugLogger, @@ -290,7 +290,7 @@ public class MusicService { queryObject.appendQueryString(querySB.toString()); queryObject.addValue(sessionId); if (isAtomic) - result = MusicCore.atomicPut(musicKeySpace, musicMetaTable, sessionId, queryObject, null); + result = MusicCore.atomicPutWithDeleteLock(musicKeySpace, musicMetaTable, sessionId, queryObject, null); else result = MusicCore.eventualPut(queryObject); logger.debug(EELFLoggerDelegate.debugLogger, "removeSession: " + musicMetaTable + " with session id: " @@ -303,7 +303,7 @@ public class MusicService { queryObject.appendQueryString(querySB.toString()); queryObject.addValue(sessionId); if (isAtomic) - result = MusicCore.atomicPut(musicKeySpace, musicAttrTable, sessionId, queryObject, null); + result = MusicCore.atomicPutWithDeleteLock(musicKeySpace, musicAttrTable, sessionId, queryObject, null); else result = MusicCore.eventualPut(queryObject); @@ -570,7 +570,7 @@ public class MusicService { try{ if (isAtomicGet) - result = MusicCore.atomicGet(musicKeySpace, musicMetaTable, null, queryObject); + result = MusicCore.atomicGetWithDeleteLock(musicKeySpace, musicMetaTable, null, queryObject); else result = MusicCore.get(queryObject); Row row = result.one(); @@ -616,7 +616,7 @@ public class MusicService { queryObject.appendQueryString(querySB.toString()); try{ if (isAtomicPut) - result = MusicCore.atomicPut(musicKeySpace, null, null, queryObject, null); + result = MusicCore.atomicPutWithDeleteLock(musicKeySpace, null, null, queryObject, null); else result = MusicCore.eventualPut(queryObject); }catch(Exception e){ @@ -634,7 +634,7 @@ public class MusicService { queryObject.appendQueryString(querySB.toString()); try{ if (isAtomicPut) - result = MusicCore.atomicPut(musicKeySpace, null, null, queryObject, null); + result = MusicCore.atomicPutWithDeleteLock(musicKeySpace, null, null, queryObject, null); else result = MusicCore.eventualPut(queryObject); }catch(Exception e){ |