Fix application peer handling of DISAPPEARED / APPEARED case 30/77630/2
authorClaudio D. Gasparini <claudio.gasparini@pantheon.tech>
Thu, 8 Nov 2018 16:36:53 +0000 (17:36 +0100)
committerRobert Varga <nite@hq.sk>
Wed, 21 Nov 2018 11:08:57 +0000 (11:08 +0000)
JIRA: BGPCEP-843

Change-Id: I82368d8cf029ffe83391333c6e11633511688b69
Signed-off-by: Claudio D. Gasparini <claudio.gasparini@pantheon.tech>
bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/ApplicationPeer.java

index 7f7a8c16cefda544dbb4a16a1d6b02af78df8c96..96e55c8d92fc28c69affce072e119df2d48e7b64 100644 (file)
@@ -191,6 +191,7 @@ public class ApplicationPeer extends AbstractPeer implements ClusteredDOMDataTre
                 final YangInstanceIdentifier tableId = this.adjRibsInId.node(tableKey).node(childIdentifier);
                 switch (child.getModificationType()) {
                     case DELETE:
+                    case DISAPPEARED:
                         LOG.trace("App peer -> AdjRibsIn path delete: {}", childIdentifier);
                         tx.delete(LogicalDatastoreType.OPERATIONAL, tableId);
                         break;
@@ -203,6 +204,7 @@ public class ApplicationPeer extends AbstractPeer implements ClusteredDOMDataTre
                             break;
                         }
                     case WRITE:
+                    case APPEARED:
                         if (child.getDataAfter().isPresent()) {
                             final NormalizedNode<?, ?> dataAfter = child.getDataAfter().get();
                             LOG.trace("App peer -> AdjRibsIn path : {}", tableId);