aboutsummaryrefslogtreecommitdiffstats
path: root/controlloop/common/controller-frankfurt/src/main/resources/frankfurt.drl
diff options
context:
space:
mode:
authorStraubs, Ralph (rs8887) <rs8887@att.com>2020-07-17 10:38:02 -0400
committerTaka Cho <takamune.cho@att.com>2020-08-28 17:03:19 -0400
commita6d4077e3639a0f3478f0cbf51e06ef46517a10d (patch)
tree1d34398ef3488d97c1dc6475372a1b8755373a8b /controlloop/common/controller-frankfurt/src/main/resources/frankfurt.drl
parentc75e28d1c1221c37ea4fd1feed9d38c75334f4db (diff)
Add tdjam-controller
the details is on wiki: https://wiki.onap.org/display/DW/tdjam+Feature+for+Tosca-Driven+Control+Loops Fixed some eclipse warnings. Revised the interaction between a manager and its SerialWorkQueue to address some threading issues. The original code started processing the event as soon as the manager was created, WHILE it was still being added to the map. During junit tests, the event responses came back, within the same thread, which then attempted to remove the manager from the map. This resulted in a ConcurrentHashMap exception. Issue-ID: POLICY-2415 Change-Id: I94a4152637be76e5b2aea2d869afd84dfb413a0e Signed-off-by: Straubs, Ralph (rs8887) <rs8887@att.com> Signed-off-by: jhh <jorge.hernandez-herrero@att.com> Signed-off-by: Taka Cho <takamune.cho@att.com> Signed-off-by: Jim Hahn <jrh3@att.com>
Diffstat (limited to 'controlloop/common/controller-frankfurt/src/main/resources/frankfurt.drl')
-rw-r--r--controlloop/common/controller-frankfurt/src/main/resources/frankfurt.drl14
1 files changed, 7 insertions, 7 deletions
diff --git a/controlloop/common/controller-frankfurt/src/main/resources/frankfurt.drl b/controlloop/common/controller-frankfurt/src/main/resources/frankfurt.drl
index 9723cec43..8169e1cdc 100644
--- a/controlloop/common/controller-frankfurt/src/main/resources/frankfurt.drl
+++ b/controlloop/common/controller-frankfurt/src/main/resources/frankfurt.drl
@@ -25,7 +25,7 @@ import org.onap.policy.controlloop.CanonicalOnset;
import org.onap.policy.controlloop.VirtualControlLoopEvent;
import org.onap.policy.controlloop.VirtualControlLoopNotification;
import org.onap.policy.controlloop.ControlLoopNotificationType;
-import org.onap.policy.controlloop.eventmanager.ControlLoopEventManager2;
+import org.onap.policy.controlloop.eventmanager.ControlLoopEventManager2Drools;
import org.onap.policy.controlloop.eventmanager.ControlLoopEventManager2.NewEventStatus;
import org.onap.policy.controlloop.eventmanager.ControlLoopOperationManager2;
import org.onap.policy.controlloop.utils.ControlLoopUtils;
@@ -98,7 +98,7 @@ rule "EVENT"
when
$params : ControlLoopParams( $clName : getClosedLoopControlName() )
$event : CanonicalOnset( closedLoopControlName == $clName )
- not ( ControlLoopEventManager2( closedLoopControlName == $event.getClosedLoopControlName(),
+ not ( ControlLoopEventManager2Drools( closedLoopControlName == $event.getClosedLoopControlName(),
getContext().getEvent() == $event ) )
then
@@ -116,7 +116,7 @@ rule "EVENT"
try {
//
// Check the event, because we need it to not be null when
- // we create the ControlLoopEventManager2. The ControlLoopEventManager2
+ // we create the ControlLoopEventManager2Drools. The ControlLoopEventManager2Drools
// will do extra syntax checking as well as check if the closed loop is disabled.
//
if ($event.getRequestId() == null) {
@@ -129,7 +129,7 @@ rule "EVENT"
notification.setPolicyVersion($params.getPolicyVersion());
} else {
- ControlLoopEventManager2 manager = new ControlLoopEventManager2($params, $event, drools.getWorkingMemory());
+ ControlLoopEventManager2Drools manager = new ControlLoopEventManager2Drools($params, $event, drools.getWorkingMemory());
insert(manager);
try {
manager.start();
@@ -171,7 +171,7 @@ end
rule "EVENT.MANAGER.NEW.EVENT"
when
$event : VirtualControlLoopEvent( )
- $manager : ControlLoopEventManager2( closedLoopControlName == $event.getClosedLoopControlName(),
+ $manager : ControlLoopEventManager2Drools( closedLoopControlName == $event.getClosedLoopControlName(),
getContext().getEvent() == $event )
then
@@ -224,7 +224,7 @@ end
*/
rule "EVENT.MANAGER.PROCESSING"
when
- $manager : ControlLoopEventManager2( isUpdated(), isActive(), $notification : getNotification() )
+ $manager : ControlLoopEventManager2Drools( isUpdated(), isActive(), $notification : getNotification() )
then
Logger logger = LoggerFactory.getLogger(drools.getRule().getPackage());
@@ -271,7 +271,7 @@ end
*/
rule "EVENT.MANAGER.FINAL"
when
- $manager : ControlLoopEventManager2( !isActive(), $notification : getNotification() )
+ $manager : ControlLoopEventManager2Drools( !isActive(), $notification : getNotification() )
then
Logger logger = LoggerFactory.getLogger(drools.getRule().getPackage());