Class ElanL2GatewayMulticastUtils
- java.lang.Object
-
- org.opendaylight.netvirt.elan.l2gw.utils.ElanL2GatewayMulticastUtils
-
@Singleton public class ElanL2GatewayMulticastUtils extends java.lang.Object
The utility class to handle ELAN L2 Gateway related to multicast.
-
-
Constructor Summary
Constructors Constructor Description ElanL2GatewayMulticastUtils(ElanItmUtils elanItmUtils, ElanUtils elanUtils, org.opendaylight.genius.mdsalutil.interfaces.IMdsalApiManager mdsalManager, org.opendaylight.genius.interfacemanager.interfaces.IInterfaceManager interfaceManager, ElanRefUtil elanRefUtil)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ExternalTeps>
buildExternalTepPath(java.lang.String elan, org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress tepIp)
protected ExternalTeps
buildExternalTeps(L2GatewayDevice device)
com.google.common.util.concurrent.FluentFuture<? extends @NonNull org.opendaylight.mdsal.common.api.CommitInfo>
deleteRemoteMcastMac(org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.NodeId nodeId, java.lang.String logicalSwitchName)
Delete remote mcast mac from Hwvtep node.DesignatedSwitchForTunnel
getDesignatedSwitchForExternalTunnel(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress tunnelIp, java.lang.String elanInstanceName)
Gets the designated switch for external tunnel.@NonNull java.util.List<org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.group.buckets.Bucket>
getRemoteBCGroupBuckets(ElanInstance elanInfo, @Nullable DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, int bucketId, long elanTag)
java.util.List<org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.group.buckets.Bucket>
getRemoteBCGroupBucketsOfElanExternalTeps(ElanInstance elanInfo, org.opendaylight.yangtools.yang.common.Uint64 dpnId, int bucketId)
java.util.List<org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.group.buckets.Bucket>
getRemoteBCGroupBucketsOfElanL2GwDevices(ElanInstance elanInfo, org.opendaylight.yangtools.yang.common.Uint64 dpnId, int bucketId)
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress
getTepIpOfDesignatedSwitchForExternalTunnel(L2GatewayDevice l2GwDevice, java.lang.String elanInstanceName)
Gets the tep ip of designated switch for external tunnel.void
handleMcastForElanL2GwDeviceAdd(java.lang.String elanName, L2GatewayDevice device)
Handle mcast for elan l2 gw device add.java.util.List<com.google.common.util.concurrent.FluentFuture<?>>
handleMcastForElanL2GwDeviceDelete(java.lang.String elanName, L2GatewayDevice l2GatewayDevice)
Handle mcast for elan l2 gw device delete.com.google.common.util.concurrent.ListenableFuture<java.lang.Void>
prepareRemoteMcastMacUpdateOnDevice(java.lang.String elanName, L2GatewayDevice device, boolean addCase, org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress removedDstTep)
void
scheduleMcastMacUpdateJob(java.lang.String elanName, L2GatewayDevice device)
void
setupElanBroadcastGroups(ElanInstance elanInfo, @Nullable DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
void
setupElanBroadcastGroups(ElanInstance elanInfo, org.opendaylight.yangtools.yang.common.Uint64 dpnId, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
void
setupLeavesEtreeBroadcastGroups(ElanInstance elanInfo, @Nullable DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
void
setupStandardElanBroadcastGroups(ElanInstance elanInfo, @Nullable DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, boolean createCase, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
void
setupStandardElanBroadcastGroups(ElanInstance elanInfo, DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
void
updateMcastMacsForAllElanDevices(java.lang.String elanName, L2GatewayDevice device, boolean updateThisDevice)
Update mcast macs for this elan.void
updateRemoteBroadcastGroupForAllElanDpns(ElanInstance elanInfo, boolean createCase, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
void
updateRemoteMcastMacOnElanL2GwDevice(java.lang.String elanName, L2GatewayDevice device)
Update remote mcast mac on elan l2 gw device.void
updateRemoteMcastMacOnElanL2GwDevices(java.lang.String elanName)
Updates the remote mcast mac table for all the devices in this elan includes all the dpn tep ips and other devices tep ips in broadcast locator set.
-
-
-
Constructor Detail
-
ElanL2GatewayMulticastUtils
@Inject public ElanL2GatewayMulticastUtils(ElanItmUtils elanItmUtils, ElanUtils elanUtils, org.opendaylight.genius.mdsalutil.interfaces.IMdsalApiManager mdsalManager, org.opendaylight.genius.interfacemanager.interfaces.IInterfaceManager interfaceManager, ElanRefUtil elanRefUtil)
-
-
Method Detail
-
handleMcastForElanL2GwDeviceAdd
public void handleMcastForElanL2GwDeviceAdd(java.lang.String elanName, L2GatewayDevice device)
Handle mcast for elan l2 gw device add.- Parameters:
elanName
- the elan namedevice
- the device
-
buildExternalTepPath
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ExternalTeps> buildExternalTepPath(java.lang.String elan, org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress tepIp)
-
buildExternalTeps
protected ExternalTeps buildExternalTeps(L2GatewayDevice device)
-
updateRemoteMcastMacOnElanL2GwDevices
public void updateRemoteMcastMacOnElanL2GwDevices(java.lang.String elanName)
Updates the remote mcast mac table for all the devices in this elan includes all the dpn tep ips and other devices tep ips in broadcast locator set.- Parameters:
elanName
- the elan to be updated
-
scheduleMcastMacUpdateJob
public void scheduleMcastMacUpdateJob(java.lang.String elanName, L2GatewayDevice device)
-
updateRemoteMcastMacOnElanL2GwDevice
public void updateRemoteMcastMacOnElanL2GwDevice(java.lang.String elanName, L2GatewayDevice device)
Update remote mcast mac on elan l2 gw device.- Parameters:
elanName
- the elan namedevice
- the device
-
prepareRemoteMcastMacUpdateOnDevice
public com.google.common.util.concurrent.ListenableFuture<java.lang.Void> prepareRemoteMcastMacUpdateOnDevice(java.lang.String elanName, L2GatewayDevice device, boolean addCase, org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress removedDstTep)
-
updateMcastMacsForAllElanDevices
public void updateMcastMacsForAllElanDevices(java.lang.String elanName, L2GatewayDevice device, boolean updateThisDevice)
Update mcast macs for this elan. for all dpns in this elan recompute and update broadcast group for all l2gw devices in this elan recompute and update remote mcast mac entry- Parameters:
elanName
- the elan namedevice
- the deviceupdateThisDevice
- the update this device
-
updateRemoteBroadcastGroupForAllElanDpns
public void updateRemoteBroadcastGroupForAllElanDpns(ElanInstance elanInfo, boolean createCase, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
-
setupElanBroadcastGroups
public void setupElanBroadcastGroups(ElanInstance elanInfo, org.opendaylight.yangtools.yang.common.Uint64 dpnId, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
-
setupElanBroadcastGroups
public void setupElanBroadcastGroups(ElanInstance elanInfo, @Nullable DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
-
setupStandardElanBroadcastGroups
public void setupStandardElanBroadcastGroups(ElanInstance elanInfo, DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
-
setupStandardElanBroadcastGroups
public void setupStandardElanBroadcastGroups(ElanInstance elanInfo, @Nullable DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, boolean createCase, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
-
setupLeavesEtreeBroadcastGroups
public void setupLeavesEtreeBroadcastGroups(ElanInstance elanInfo, @Nullable DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx)
-
getRemoteBCGroupBuckets
public @NonNull java.util.List<org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.group.buckets.Bucket> getRemoteBCGroupBuckets(ElanInstance elanInfo, @Nullable DpnInterfaces dpnInterfaces, org.opendaylight.yangtools.yang.common.Uint64 dpnId, int bucketId, long elanTag)
-
getRemoteBCGroupBucketsOfElanL2GwDevices
public java.util.List<org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.group.buckets.Bucket> getRemoteBCGroupBucketsOfElanL2GwDevices(ElanInstance elanInfo, org.opendaylight.yangtools.yang.common.Uint64 dpnId, int bucketId)
-
getRemoteBCGroupBucketsOfElanExternalTeps
public java.util.List<org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.group.buckets.Bucket> getRemoteBCGroupBucketsOfElanExternalTeps(ElanInstance elanInfo, org.opendaylight.yangtools.yang.common.Uint64 dpnId, int bucketId)
-
handleMcastForElanL2GwDeviceDelete
public java.util.List<com.google.common.util.concurrent.FluentFuture<?>> handleMcastForElanL2GwDeviceDelete(java.lang.String elanName, L2GatewayDevice l2GatewayDevice)
Handle mcast for elan l2 gw device delete.- Parameters:
elanName
- the elan instance namel2GatewayDevice
- the l2 gateway device- Returns:
- the listenable future
-
deleteRemoteMcastMac
public com.google.common.util.concurrent.FluentFuture<? extends @NonNull org.opendaylight.mdsal.common.api.CommitInfo> deleteRemoteMcastMac(org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.NodeId nodeId, java.lang.String logicalSwitchName)
Delete remote mcast mac from Hwvtep node.- Parameters:
nodeId
- the node idlogicalSwitchName
- the logical switch name- Returns:
- the listenable future
-
getTepIpOfDesignatedSwitchForExternalTunnel
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress getTepIpOfDesignatedSwitchForExternalTunnel(L2GatewayDevice l2GwDevice, java.lang.String elanInstanceName)
Gets the tep ip of designated switch for external tunnel.- Parameters:
l2GwDevice
- the l2 gw deviceelanInstanceName
- the elan instance name- Returns:
- the tep ip of designated switch for external tunnel
-
getDesignatedSwitchForExternalTunnel
public DesignatedSwitchForTunnel getDesignatedSwitchForExternalTunnel(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress tunnelIp, java.lang.String elanInstanceName)
Gets the designated switch for external tunnel.- Parameters:
tunnelIp
- the tunnel ipelanInstanceName
- the elan instance name- Returns:
- the designated switch for external tunnel
-
-