import org.openecomp.policy.api.PolicyEngine;
import org.openecomp.policy.api.PolicyEngineException;
import org.openecomp.policy.api.RemovedPolicy;
import org.openecomp.policy.api.PolicyEngine;
import org.openecomp.policy.api.PolicyEngineException;
import org.openecomp.policy.api.RemovedPolicy;
@Override
public void notificationReceived(PDPNotification notification) {
System.out.println("Notification Received...");
@Override
public void notificationReceived(PDPNotification notification) {
System.out.println("Notification Received...");
// Checking the Name is correct or not.
try {
PolicyEngine policyEngine = new PolicyEngine("config.properties");
// Checking the Name is correct or not.
try {
PolicyEngine policyEngine = new PolicyEngine("config.properties");
Collection<PolicyConfig> policyConfigs = policyEngine.getConfigByPolicyName(updatedPolicy.getPolicyName());
for(PolicyConfig policyConfig: policyConfigs){
if(policyConfig.getPolicyConfigStatus().equals(PolicyConfigStatus.CONFIG_RETRIEVED)){
Collection<PolicyConfig> policyConfigs = policyEngine.getConfigByPolicyName(updatedPolicy.getPolicyName());
for(PolicyConfig policyConfig: policyConfigs){
if(policyConfig.getPolicyConfigStatus().equals(PolicyConfigStatus.CONFIG_RETRIEVED)){
// Checking the Name is correct or not.
try {
PolicyEngine policyEngine = new PolicyEngine("config.properties");
// Checking the Name is correct or not.
try {
PolicyEngine policyEngine = new PolicyEngine("config.properties");
Collection<PolicyConfig> policyConfigs = policyEngine.getConfigByPolicyName(updatedPolicy.getPolicyName());
for(PolicyConfig policyConfig: policyConfigs){
if(policyConfig.getPolicyConfigStatus().equals(PolicyConfigStatus.CONFIG_RETRIEVED)){
Collection<PolicyConfig> policyConfigs = policyEngine.getConfigByPolicyName(updatedPolicy.getPolicyName());
for(PolicyConfig policyConfig: policyConfigs){
if(policyConfig.getPolicyConfigStatus().equals(PolicyConfigStatus.CONFIG_RETRIEVED)){