aboutsummaryrefslogtreecommitdiffstats
path: root/main/src/main/java/org/onap/policy/pap/main/notification/DeploymentTracker.java
diff options
context:
space:
mode:
Diffstat (limited to 'main/src/main/java/org/onap/policy/pap/main/notification/DeploymentTracker.java')
-rw-r--r--main/src/main/java/org/onap/policy/pap/main/notification/DeploymentTracker.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/main/src/main/java/org/onap/policy/pap/main/notification/DeploymentTracker.java b/main/src/main/java/org/onap/policy/pap/main/notification/DeploymentTracker.java
index cef70a39..4522debb 100644
--- a/main/src/main/java/org/onap/policy/pap/main/notification/DeploymentTracker.java
+++ b/main/src/main/java/org/onap/policy/pap/main/notification/DeploymentTracker.java
@@ -146,6 +146,14 @@ public class DeploymentTracker {
newStatus.setPolicyTypeId(status.getPolicyTypeId());
newStatus.setPolicyTypeVersion(status.getPolicyTypeVersion());
+ /*
+ * Adding the status to the "added" set may be a bit unexpected, but when all
+ * status records are deleted from the group, we don't actually undeploy the
+ * policy from the subgroup. Instead, we leave it in the subgroup so that as
+ * soon as a PDP registers, we immediately deploy the policy to the PDP and
+ * continue on; the client can always undeploy the policy when it receives the
+ * notification, if so desired.
+ */
notif.getAdded().add(newStatus);
}
}