summaryrefslogtreecommitdiffstats
path: root/controlloop/common/controller-usecases/src
diff options
context:
space:
mode:
authorJim Hahn <jrh3@att.com>2020-06-29 17:43:07 -0400
committerJim Hahn <jrh3@att.com>2020-06-29 17:44:28 -0400
commitc2e0698897c060a91a5212f8f42d8aa2a9b96e65 (patch)
tree62dc0d58d1f4a4350e96ad24159882ecd0aed445 /controlloop/common/controller-usecases/src
parent5814190df5c082e5b681baf336f9e45ba88c3658 (diff)
Fix build breakage in drools-apps due to pair
The Pair changes made in drools-pdp also broke drools-apps builds. Replaced usage of drools.utils.Pair with apache Pair. Issue-ID: POLICY-2202 Change-Id: I50aaad47c243637688602ae6cb680a929fe3edd9 Signed-off-by: Jim Hahn <jrh3@att.com>
Diffstat (limited to 'controlloop/common/controller-usecases/src')
-rw-r--r--controlloop/common/controller-usecases/src/main/resources/usecases.drl15
1 files changed, 8 insertions, 7 deletions
diff --git a/controlloop/common/controller-usecases/src/main/resources/usecases.drl b/controlloop/common/controller-usecases/src/main/resources/usecases.drl
index 3fe2cddbf..dabc02f68 100644
--- a/controlloop/common/controller-usecases/src/main/resources/usecases.drl
+++ b/controlloop/common/controller-usecases/src/main/resources/usecases.drl
@@ -21,6 +21,8 @@
package org.onap.policy.controlloop;
+import org.apache.commons.lang3.tuple.Pair;
+
import org.onap.ccsdk.cds.controllerblueprints.processing.api.ExecutionServiceInput;
import org.onap.policy.controlloop.drl.legacy.ControlLoopParams;
import org.onap.policy.controlloop.CanonicalOnset;
@@ -50,7 +52,6 @@ import org.onap.policy.appclcm.AppcLcmDmaapWrapper;
import org.onap.policy.cds.CdsResponse;
import org.onap.policy.cds.client.CdsProcessorGrpcClient;
import org.onap.policy.cds.properties.CdsServerProperties;
-import org.onap.policy.drools.utils.Pair;
import org.onap.policy.sdnr.PciRequestWrapper;
import org.onap.policy.sdnr.PciResponseWrapper;
import org.onap.policy.sdnr.PciRequest;
@@ -432,15 +433,15 @@ rule "EVENT.MANAGER"
Pair<Lock,Lock> oldNew = $manager.lockCurrentOperation(
new LockCallbackWorkingMemory($params.getClosedLoopControlName(), drools.getWorkingMemory()));
- if(oldNew.first() != null) {
+ if(oldNew.getLeft() != null) {
logger.debug("{}: {}.{}: retracting lock={}", $clName,
- $params.getPolicyName(), drools.getRule().getName(), oldNew.first());
- retract(oldNew.first());
+ $params.getPolicyName(), drools.getRule().getName(), oldNew.getLeft());
+ retract(oldNew.getLeft());
}
- if(oldNew.second() != null) {
+ if(oldNew.getRight() != null) {
logger.debug("{}: {}.{}: inserting lock={}", $clName,
- $params.getPolicyName(), drools.getRule().getName(), oldNew.second());
- insert(oldNew.second());
+ $params.getPolicyName(), drools.getRule().getName(), oldNew.getRight());
+ insert(oldNew.getRight());
}
//