Bug 7147: VpnInterfaces not removed when InterVpnLink is removed 25/48225/3
authorMiguel Perez <francisco.miguel.perez@ericsson.com>
Thu, 10 Nov 2016 16:22:45 +0000 (17:22 +0100)
committerSam Hague <shague@redhat.com>
Fri, 11 Nov 2016 21:13:05 +0000 (21:13 +0000)
 + Current code is trying to remove them from CONFIGURATION, but it
   should be OPERATIONAL

Change-Id: Icaa91b5060340c4816358314b469b4a4789a5edd
Signed-off-by: Miguel Perez <francisco.miguel.perez@ericsson.com>
vpnservice/vpnmanager/vpnmanager-impl/src/main/java/org/opendaylight/netvirt/vpnmanager/VpnUtil.java

index e03d5bf2cbd6982e0c31f3c75807739899d195af..84181f271a443088c05e307e04c7f30e81d53cf1 100644 (file)
@@ -984,7 +984,7 @@ public class VpnUtil {
      * @param ifaceName interface name.
      */
     public static void removeIfaceFromVpnToDpnMap(DataBroker broker, String rd, BigInteger dpnId, String ifaceName) {
-        tryDelete(broker, LogicalDatastoreType.CONFIGURATION, getVpnToDpnInterfacePath(rd, dpnId, ifaceName));
+        tryDelete(broker, LogicalDatastoreType.OPERATIONAL, getVpnToDpnInterfacePath(rd, dpnId, ifaceName));
         // Note: tryDelete is a best-effort. Sometimes we want to update the VpnToDpnMap ifaces when the
         // DPN has gone down (and the VpnToDpnMap has been removed in a different Thread)
     }
@@ -1445,4 +1445,4 @@ public class VpnUtil {
 
     }
 
-}
\ No newline at end of file
+}