From 149df90bb72ece740accaf3ea037cf40defcd1bd Mon Sep 17 00:00:00 2001 From: jhh Date: Tue, 9 Mar 2021 10:01:17 -0600 Subject: add no locking feature It provides an interface to applications for locking purposes that always succeeds. It does not deny acquiring resource locks. Issue-ID: POLICY-3114 Signed-off-by: jhh Change-Id: I6aebb5f40e4176e0ff7b0e6c6d4042a79dd0b7a3 Signed-off-by: jhh --- policy-core/pom.xml | 4 +- .../policy/drools/core/lock/AlwaysSuccessLock.java | 64 +++++++++++++++++++ .../drools/core/lock/AlwaysFailLockTest.java | 61 ++----------------- .../drools/core/lock/AlwaysLockBaseTest.java | 71 ++++++++++++++++++++++ .../drools/core/lock/AlwaysSuccessLockTest.java | 69 +++++++++++++++++++++ 5 files changed, 210 insertions(+), 59 deletions(-) create mode 100644 policy-core/src/main/java/org/onap/policy/drools/core/lock/AlwaysSuccessLock.java create mode 100644 policy-core/src/test/java/org/onap/policy/drools/core/lock/AlwaysLockBaseTest.java create mode 100644 policy-core/src/test/java/org/onap/policy/drools/core/lock/AlwaysSuccessLockTest.java (limited to 'policy-core') diff --git a/policy-core/pom.xml b/policy-core/pom.xml index af01bc93..33a9e12b 100644 --- a/policy-core/pom.xml +++ b/policy-core/pom.xml @@ -1,7 +1,7 @@