EVPN RT2 elan changes to adv/withdraw RT2 routes..
[netvirt.git] / vpnservice / vpnmanager / vpnmanager-api / src / main / java / org / opendaylight / netvirt / vpnmanager / api / IVpnManager.java
index 455edd4505ef807765fd773903a0febd1067fadd..ac5c93c32626b8a4a4f528ccfb3ecc0d7cfc5c93 100644 (file)
@@ -11,20 +11,21 @@ package org.opendaylight.netvirt.vpnmanager.api;
 import java.math.BigInteger;
 import java.util.Collection;
 import java.util.List;
-
+import org.opendaylight.controller.md.sal.binding.api.DataBroker;
 import org.opendaylight.controller.md.sal.binding.api.WriteTransaction;
 import org.opendaylight.genius.mdsalutil.MatchInfoBase;
-import org.opendaylight.netvirt.fibmanager.api.IFibManager;
 import org.opendaylight.netvirt.fibmanager.api.RouteOrigin;
+import org.opendaylight.yang.gen.v1.urn.huawei.params.xml.ns.yang.l3vpn.rev140815.vpn.instances.VpnInstance;
 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.Uuid;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.netvirt.neutronvpn.rev150602.neutron.vpn.portip.port.data.VpnPortipToPort;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.netvirt.neutronvpn.rev150602.subnetmaps.Subnetmap;
 
-public interface IVpnManager {
-    void setFibManager(IFibManager fibManager);
 
+public interface IVpnManager {
     void addExtraRoute(String vpnName, String destination, String nextHop,
             String rd, String routerID, int label, RouteOrigin origin);
 
-    void delExtraRoute(String destination, String nextHop, String rd, String routerID);
+    void delExtraRoute(String vpnName, String destination, String nextHop, String rd, String routerID);
 
     /**
      * Returns true if the specified VPN exists.
@@ -35,8 +36,6 @@ public interface IVpnManager {
 
     boolean isVPNConfigured();
 
-    long getArpCacheTimeoutMillis();
-
     /**
      * Retrieves the list of DPNs where the specified VPN has footprint.
      *
@@ -45,17 +44,6 @@ public interface IVpnManager {
      */
     List<BigInteger> getDpnsOnVpn(String vpnInstanceName);
 
-    /**
-     * Updates the footprint that a VPN has on a given DPN by adding/removing
-     * the specified interface.
-     *
-     * @param dpId DPN where the VPN interface belongs to
-     * @param vpnName Name of the VPN whose footprint is being modified
-     * @param interfaceName Name of the VPN interface to be added/removed to/from the specified DPN
-     * @param add true for addition, false for removal
-     */
-    void updateVpnFootprint(BigInteger dpId, String vpnName, String interfaceName, boolean add);
-
     void setupSubnetMacIntoVpnInstance(String vpnName, String subnetVpnName, String srcMacAddress,
             BigInteger dpnId, WriteTransaction writeTx, int addOrRemove);
 
@@ -69,6 +57,16 @@ public interface IVpnManager {
             BigInteger dpnId, long vpnId, String extInterfaceName, int lportTag, WriteTransaction writeTx,
             int addOrRemove);
 
+    void onSubnetAddedToVpn(Subnetmap subnetmap, boolean isBgpVpn, Long elanTag);
+
+    void onSubnetDeletedFromVpn(Subnetmap subnetmap, boolean isBgpVpn);
+
     List<MatchInfoBase> getEgressMatchesForVpn(String vpnName);
 
+    VpnInstance getVpnInstance(DataBroker broker, String vpnInstanceName);
+
+    String getVpnRd(DataBroker broker, String vpnName);
+
+    VpnPortipToPort getNeutronPortFromVpnPortFixedIp(DataBroker broker, String vpnName, String fixedIp);
+
 }