aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormpriyank <priyank.maheshwari@est.tech>2024-12-20 11:31:58 +0000
committermpriyank <priyank.maheshwari@est.tech>2024-12-20 11:32:48 +0000
commit943ce278e766f4ca221134613b79c5f311141f22 (patch)
tree7e51394c6489b080c0d294f82fadfeec03b6a460
parent199be45ab573c3917d9ebefdeaf8b599f8944cd8 (diff)
Update docs related to lock
- added the distributed lock in the documentation as well - updated the log level to debug to refrain printing every iteration of the scheduler Issue-ID: CPS-2479 Change-Id: Ieeeff46168d70aca6f423e82bda15a12d6c405a5 Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
-rw-r--r--cps-ncmp-service/src/main/java/org/onap/cps/ncmp/impl/inventory/sync/ModuleSyncWatchdog.java4
-rw-r--r--docs/deployment.rst4
2 files changed, 5 insertions, 3 deletions
diff --git a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/impl/inventory/sync/ModuleSyncWatchdog.java b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/impl/inventory/sync/ModuleSyncWatchdog.java
index 5b71a8af70..32e1c49f17 100644
--- a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/impl/inventory/sync/ModuleSyncWatchdog.java
+++ b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/impl/inventory/sync/ModuleSyncWatchdog.java
@@ -92,7 +92,7 @@ public class ModuleSyncWatchdog {
*/
public void populateWorkQueueIfNeeded() {
if (moduleSyncWorkQueue.isEmpty() && cpsAndNcmpLock.tryLock(MODULE_SYNC_WORK_QUEUE_LOCK_NAME)) {
- log.info("Lock acquired by thread : {}", Thread.currentThread().getName());
+ log.debug("Lock acquired by thread : {}", Thread.currentThread().getName());
try {
populateWorkQueue();
if (moduleSyncWorkQueue.isEmpty()) {
@@ -100,7 +100,7 @@ public class ModuleSyncWatchdog {
}
} finally {
cpsAndNcmpLock.unlock(MODULE_SYNC_WORK_QUEUE_LOCK_NAME);
- log.info("Lock released by thread : {}", Thread.currentThread().getName());
+ log.debug("Lock released by thread : {}", Thread.currentThread().getName());
}
}
}
diff --git a/docs/deployment.rst b/docs/deployment.rst
index 9823fa2f8a..2a17e30a16 100644
--- a/docs/deployment.rst
+++ b/docs/deployment.rst
@@ -357,5 +357,7 @@ Below are the list of distributed datastructures that we have.
| cps-ncmp | moduleSetTagsBeingProcessed | Track module set tags which are processed to prevent |
| | | multiple threads working with same tag. |
+--------------+------------------------------------+-----------------------------------------------------------+
+| cps-ncmp | cpsAndNcmpLock | Cps and NCMP distributed lock for various use cases. |
++--------------+------------------------------------+-----------------------------------------------------------+
-Total number of caches : 7
+Total number of caches : 8