- if (isCorrelated($a, $b)){
- // If any of the alarms have been marked as root, a policy message has ever been created and sent. Do NOT send it again.
- if ($a.getRootFlag() != 1 && $b.getRootFlag() != 1) {
- PolicyMsg msg = createPolicyMsg($a);
- DmaapService dmaapService = ServiceLocatorHolder.getLocator().getService(DmaapService.class);
- dmaapService.publishPolicyMsg(msg, "unauthenticated.DCAE_CL_OUTPUT");
- }
- $a.setRootFlag(1);
- $b.setRootFlag(1);
- update($a);
- update($b);
+ String status = "down";
+ if (status.equalsIgnoreCase(getAdditionalField($a, "oper-status"))
+ && status.equalsIgnoreCase(getAdditionalField($b, "oper-status"))) {
+ if (isCorrelated($a, $b)){
+ // If any of the alarms have been marked as root, a policy message has ever been created and sent. Do NOT send it again.
+ if ($a.getRootFlag() != 1 && $b.getRootFlag() != 1) {
+ PolicyMsg msg = createPolicyMsg($a);
+ DmaapService dmaapService = ServiceLocatorHolder.getLocator().getService(DmaapService.class);
+ dmaapService.publishPolicyMsg(msg, "unauthenticated.DCAE_CL_OUTPUT");
+ updateAaiLinkStatus(getLogicLink($a), status);
+ }
+ $a.setRootFlag(1);
+ $b.setRootFlag(1);
+ update($a);
+ update($b);
+ }