From 8014ef7e259a46b3c2128f3b9628a48b758be9cb Mon Sep 17 00:00:00 2001 From: Mohammad Salehe Date: Fri, 8 Feb 2019 11:25:38 -0500 Subject: More detailed error messages for lock references Change-Id: Id2be5f781e95e2252b6e8cafecc0fd18f2ed5366 Issue-ID: MUSIC-148 Signed-off-by: Mohammad Salehe --- src/main/java/org/onap/music/service/impl/MusicCassaCore.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/org/onap/music/service/impl/MusicCassaCore.java b/src/main/java/org/onap/music/service/impl/MusicCassaCore.java index 1866a5c7..343ba1f1 100644 --- a/src/main/java/org/onap/music/service/impl/MusicCassaCore.java +++ b/src/main/java/org/onap/music/service/impl/MusicCassaCore.java @@ -185,19 +185,19 @@ public class MusicCassaCore implements MusicCoreService { return new ReturnType(ResultType.SUCCESS, lockReference + " can read the values"); } logger.info(EELFLoggerDelegate.applicationLogger, - lockReference + " is not the lock holder yet"); + primaryKeyValue + " " + lockReference + " is not the lock holder yet"); return new ReturnType(ResultType.FAILURE, lockReference + " is not the lock holder yet"); } if (lockReferenceL < topOfLockStoreL) { logger.info(EELFLoggerDelegate.applicationLogger, - lockReference + " is no longer/or was never in the lock store queue"); + primaryKeyValue + " " + lockReference + " is no longer/or was never in the lock store queue"); return new ReturnType(ResultType.FAILURE, lockReference + " is no longer/or was never in the lock store queue"); } - return new ReturnType(ResultType.SUCCESS, lockReference + " is top of lock store"); + return new ReturnType(ResultType.SUCCESS, primaryKeyValue + " " + lockReference + " is top of lock store"); } finally { TimeMeasureInstance.instance().exit(); @@ -241,7 +241,7 @@ public class MusicCassaCore implements MusicCoreService { getLockingServiceHandle().updateLockAcquireTime(keyspace, table, primaryKeyValue, lockReference); - return new ReturnType(ResultType.SUCCESS, lockReference + " is the lock holder for the key"); + return new ReturnType(ResultType.SUCCESS, primaryKeyValue + " " + lockReference + " is the lock holder for the key"); } finally { TimeMeasureInstance.instance().exit(); -- cgit 1.2.3-korg