diff options
author | mpriyank <priyank.maheshwari@est.tech> | 2023-03-27 12:54:45 +0100 |
---|---|---|
committer | mpriyank <priyank.maheshwari@est.tech> | 2023-03-27 12:54:51 +0100 |
commit | 100cfebb4b550f23b5b304d4913c46dda0c06154 (patch) | |
tree | b7ae058bf8dc4490396b2f9c67973362edf6d362 /cps-ncmp-service/src/main | |
parent | 209082fed03f8e710f81c62c31600346724d9b3d (diff) |
Enhanced logging for bug
- Added minor logging and temporarily converted some debug logs to info
level
Issue-ID: CPS-1566
Change-Id: I2c706ecd601b06f2a92388b318a44640c682bdd1
Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
Diffstat (limited to 'cps-ncmp-service/src/main')
-rw-r--r-- | cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/inventory/sync/ModuleSyncWatchdog.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/inventory/sync/ModuleSyncWatchdog.java b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/inventory/sync/ModuleSyncWatchdog.java index 8acaa0abe3..e2330a7135 100644 --- a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/inventory/sync/ModuleSyncWatchdog.java +++ b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/inventory/sync/ModuleSyncWatchdog.java @@ -69,7 +69,7 @@ public class ModuleSyncWatchdog { while (!moduleSyncWorkQueue.isEmpty()) { if (batchCounter.get() <= asyncTaskParallelismLevel) { final Collection<DataNode> nextBatch = prepareNextBatch(); - log.debug("Processing module sync batch of {}. {} batch(es) active.", + log.info("Processing module sync batch of {}. {} batch(es) active.", nextBatch.size(), batchCounter.get()); asyncTaskExecutor.executeTask(() -> moduleSyncTasks.performModuleSync(nextBatch, batchCounter), @@ -118,15 +118,16 @@ public class ModuleSyncWatchdog { final Collection<DataNode> nextBatchCandidates = new HashSet<>(MODULE_SYNC_BATCH_SIZE); final Collection<DataNode> nextBatch = new HashSet<>(MODULE_SYNC_BATCH_SIZE); moduleSyncWorkQueue.drainTo(nextBatchCandidates, MODULE_SYNC_BATCH_SIZE); - log.debug("nextBatchCandidates size : {}", nextBatchCandidates.size()); + log.info("nextBatchCandidates size : {}", nextBatchCandidates.size()); for (final DataNode batchCandidate : nextBatchCandidates) { final String cmHandleId = String.valueOf(batchCandidate.getLeaves().get("id")); final boolean alreadyAddedToInProgressMap = VALUE_FOR_HAZELCAST_IN_PROGRESS_MAP.equals( moduleSyncStartedOnCmHandles.putIfAbsent(cmHandleId, VALUE_FOR_HAZELCAST_IN_PROGRESS_MAP, SynchronizationCacheConfig.MODULE_SYNC_STARTED_TTL_SECS, TimeUnit.SECONDS)); if (alreadyAddedToInProgressMap) { - log.debug("module sync for {} already in progress by other instance", cmHandleId); + log.info("module sync for {} already in progress by other instance", cmHandleId); } else { + log.info("Adding cmHandle : {} to current batch", cmHandleId); nextBatch.add(batchCandidate); } } |