@Singleton public class ElanUtils extends Object
Modifier and Type | Field and Description |
---|---|
static com.google.common.util.concurrent.FutureCallback<Void> |
DEFAULT_CALLBACK |
Constructor and Description |
---|
ElanUtils(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker,
org.opendaylight.genius.mdsalutil.interfaces.IMdsalApiManager mdsalManager,
org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.rpcs.rev160406.OdlInterfaceRpcService interfaceManagerRpcService,
org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.rpcs.rev160406.ItmRpcService itmRpcService,
ElanConfig elanConfig,
org.opendaylight.genius.interfacemanager.interfaces.IInterfaceManager interfaceManager,
ElanEtreeUtils elanEtreeUtils,
ElanItmUtils elanItmUtils,
ElanInterfaceCache elanInterfaceCache,
org.opendaylight.genius.itm.api.IITMProvider iitmProvider) |
Modifier and Type | Method and Description |
---|---|
void |
addDmacRedirectToDispatcherFlows(Long elanTag,
String displayName,
String macAddress,
List<BigInteger> dpnIds) |
static org.opendaylight.genius.mdsalutil.FlowEntity |
buildDmacRedirectToDispatcherFlow(BigInteger dpId,
String dstMacAddress,
String displayName,
long elanTag) |
org.opendaylight.genius.mdsalutil.FlowEntity |
buildKnownSmacFlow(ElanInstance elanInfo,
org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo,
long macTimeout,
String macAddress) |
org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.tables.table.Flow |
buildLocalDmacFlowEntry(long elanTag,
BigInteger dpId,
String ifName,
String macAddress,
ElanInstance elanInfo,
long ifTag)
Builds the flow to be programmed in the DMAC table of the local DPN (that
is, where the MAC is attached to).
|
static List<org.opendaylight.genius.mdsalutil.MatchInfo> |
buildMatchesForElanTagShFlagAndDstMac(long elanTag,
boolean shFlag,
String macAddr) |
org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.tables.table.Flow |
buildRemoteDmacFlowEntry(BigInteger srcDpId,
BigInteger destDpId,
long lportTagOrVni,
long elanTag,
String macAddress,
String displayName,
ElanInstance elanInstance)
Builds a Flow to be programmed in a remote DPN's DMAC table.
|
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.servicebinding.rev160406.service.bindings.services.info.BoundServices> |
buildServiceId(String interfaceName,
short serviceIndex) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.state.Interface> |
createInterfaceStateInstanceIdentifier(String interfaceName)
Creates the interface state instance identifier.
|
static <T extends org.opendaylight.yangtools.yang.binding.DataObject> |
delete(org.opendaylight.controller.md.sal.binding.api.DataBroker broker,
org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType,
org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path) |
void |
deleteMacFlows(@Nullable ElanInstance elanInfo,
@Nullable org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo,
MacEntry macEntry,
org.opendaylight.genius.infra.TypedReadWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> flowTx) |
void |
deleteMacFlows(ElanInstance elanInfo,
org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo,
String macAddress,
boolean deleteSmac,
org.opendaylight.genius.infra.TypedReadWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> flowTx) |
static <T> List<T> |
diffOf(List<T> orig,
List<T> updated) |
List<org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.op.rev160406.external.tunnel.list.ExternalTunnel> |
getAllExternalTunnels(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType)
Gets the all external tunnels.
|
static org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.servicebinding.rev160406.service.bindings.services.info.BoundServices |
getBoundServices(String serviceName,
short servicePriority,
int flowPriority,
BigInteger cookie,
List<org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.list.Instruction> instructions) |
@NonNull List<org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.list.Action> |
getEgressActionsForInterface(String ifName,
@Nullable Long tunnelKey)
Returns the list of Actions to be taken when sending the packet through
an Elan interface.
|
static @Nullable Elan |
getElanByName(org.opendaylight.controller.md.sal.binding.api.DataBroker broker,
String elanInstanceName) |
static @Nullable Elan |
getElanByName(org.opendaylight.genius.infra.TypedReadTransaction<org.opendaylight.genius.infra.Datastore.Operational> tx,
String elanInstanceName) |
@NonNull List<DpnInterfaces> |
getElanDPNByName(String elanInstanceName) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<DpnInterfaces> |
getElanDpnInterfaceOperationalDataPath(String elanInstanceName,
BigInteger dpId)
Returns the InstanceIdentifier that points to the Interfaces of an Elan
in a given DPN in the Operational DS.
|
@Nullable ElanDpnInterfaces |
getElanDpnInterfacesList() |
@Nullable ElanDpnInterfacesList |
getElanDpnInterfacesList(String elanName) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ElanDpnInterfacesList> |
getElanDpnOperationDataPath(String elanInstanceName) |
@Nullable ElanTagName |
getElanInfoByElanTag(long elanTag) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ElanTagName> |
getElanInfoEntriesOperationalDataPath(long elanTag) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<Elan> |
getElanInstanceOperationalDataPath(String elanInstanceName) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ElanInterface> |
getElanInterfaceConfigurationDataPathId(String interfaceName) |
@Nullable DpnInterfaces |
getElanInterfaceInfoByElanDpn(String elanInstanceName,
BigInteger dpId)
Returns the list of Interfaces that belong to an Elan on an specific DPN.
|
static String |
getElanInterfaceJobKey(String interfaceName) |
static @Nullable ElanInterfaceMac |
getElanInterfaceMacByInterfaceName(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker,
String interfaceName) |
ElanInterfaceMac |
getElanInterfaceMacByInterfaceName(String interfaceName) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ElanInterfaceMac> |
getElanInterfaceMacEntriesOperationalDataPath(String interfaceName) |
static long |
getElanLocalBCGId(long elanTag) |
List<MacEntry> |
getElanMacEntries(String elanName) |
static @Nullable MacTable |
getElanMacTable(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker,
String elanName) |
@Nullable MacTable |
getElanMacTable(String elanName)
Gets the elan mac table.
|
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacTable> |
getElanMacTableOperationalDataPath(String elanName) |
static BigInteger |
getElanMetadataLabel(long elanTag,
boolean isSHFlagSet) |
static long |
getElanRemoteBCGId(long elanTag) |
static long |
getElanRemoteBroadCastGroupID(long elanTag) |
static String |
getElanServiceName(String elanName,
String interfaceName) |
static long |
getEtreeLeafLocalBCGId(long etreeLeafTag) |
static long |
getEtreeLeafRemoteBCGId(long etreeLeafTag) |
@Nullable String |
getExternalElanInterface(String elanInstanceName,
BigInteger dpnId) |
@Nullable org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.op.rev160406.external.tunnel.list.ExternalTunnel |
getExternalTunnel(String interfaceName,
org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType)
Gets the external tunnel.
|
@Nullable org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.op.rev160406.external.tunnel.list.ExternalTunnel |
getExternalTunnel(String sourceDevice,
String destinationDevice,
org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType)
Gets the external tunnel.
|
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.tables.table.Flow> |
getFlowIid(org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.tables.table.Flow flow,
BigInteger dpnId) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.groups.Group> |
getGroupInstanceid(BigInteger dpnId,
long groupId) |
List<org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.list.Instruction> |
getInstructionsInPortForOutGroup(String ifName)
Constructs the Instructions that take the packet over a given interface.
|
com.google.common.base.Optional<org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.meta.rev160406._if.indexes._interface.map.IfIndexInterface> |
getInterfaceInfoByInterfaceTag(long interfaceTag) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.meta.rev160406._if.indexes._interface.map.IfIndexInterface> |
getInterfaceInfoEntriesOperationalDataPath(long interfaceTag) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacEntry> |
getInterfaceMacEntriesIdentifierOperationalDataPath(String interfaceName,
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress) |
@Nullable MacEntry |
getInterfaceMacEntriesOperationalDataPath(String interfaceName,
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress) |
@Nullable MacEntry |
getInterfaceMacEntriesOperationalDataPathFromId(org.opendaylight.genius.infra.TypedReadTransaction<org.opendaylight.genius.infra.Datastore.Operational> tx,
org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacEntry> identifier) |
static org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.state.Interface |
getInterfaceStateFromOperDS(String interfaceName,
org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker)
Gets the interface state from operational ds.
|
static String |
getIntTunnelTableFlowRef(short tableId,
int elanTag)
Constructs the FlowName for flows installed in the Internal Tunnel Table,
consisting in tableId + elanTag.
|
@NonNull List<DpnInterfaces> |
getInvolvedDpnsInElan(String elanName) |
static String |
getKnownDynamicmacFlowRef(short tableId,
BigInteger dpId,
BigInteger remoteDpId,
String macAddress,
long elanTag) |
static String |
getKnownDynamicmacFlowRef(short tableId,
BigInteger dpId,
long lporTag,
String macAddress,
long elanTag) |
static String |
getKnownDynamicmacFlowRef(short tableId,
BigInteger dpId,
String macAddress,
long elanTag) |
static String |
getKnownDynamicmacFlowRef(short elanDmacTable,
BigInteger dpId,
String extDeviceNodeId,
String dstMacAddress,
long elanTag,
boolean shFlag) |
com.google.common.base.Optional<MacEntry> |
getMacEntryForElanInstance(String elanName,
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress) |
com.google.common.base.Optional<MacEntry> |
getMacEntryForElanInstance(org.opendaylight.genius.infra.TypedReadTransaction<org.opendaylight.genius.infra.Datastore.Operational> tx,
String elanName,
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress) |
@Nullable MacEntry |
getMacEntryFromElanMacId(org.opendaylight.genius.infra.TypedReadTransaction<org.opendaylight.genius.infra.Datastore.Operational> tx,
org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacEntry> identifier) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacEntry> |
getMacEntryOperationalDataPath(String elanName,
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress) |
@NonNull List<BigInteger> |
getParticipatingDpnsInElanInstance(String elanInstanceName)
This method is useful get all ELAN participating CSS dpIds to install
program remote dmac entries and updating remote bc groups for tor
integration.
|
static List<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress> |
getPhysAddress(List<String> macAddress) |
static @Nullable String |
getRouterPordIdFromElanInstance(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker,
String elanInstanceName) |
com.google.common.base.Optional<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress> |
getSourceIpAddress(org.opendaylight.genius.mdsalutil.packet.Ethernet ethernet) |
static List<StaticMacEntries> |
getStaticMacEntries(List<String> staticMacAddresses) |
static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<StaticMacEntries> |
getStaticMacEntriesCfgDataPathIdentifier(String interfaceName,
String macAddress) |
static List<org.opendaylight.genius.mdsalutil.MatchInfo> |
getTunnelIdMatchForFilterEqualsLPortTag(int lportTag)
Constructs the Matches that checks that the tunnel_id field contains a
specific lportTag.
|
static List<org.opendaylight.genius.mdsalutil.MatchInfo> |
getTunnelMatchesForServiceId(int elanTag) |
static Long |
getVxlanSegmentationId(ElanInstance elanInstance) |
boolean |
isDpnPresent(BigInteger dpnId) |
static boolean |
isEmpty(Collection collection) |
static boolean |
isFlat(ElanInstance elanInstance) |
static boolean |
isInterfaceOperational(String interfaceName,
org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker)
Checks if is interface operational.
|
static boolean |
isNotEmpty(Collection collection) |
Boolean |
isOpenstackVniSemanticsEnforced() |
boolean |
isTunnelInLogicalGroup(String interfaceName) |
static boolean |
isVlan(ElanInstance elanInstance) |
static boolean |
isVxlan(@Nullable ElanInstance elanInstance) |
static boolean |
isVxlanNetworkOrVxlanSegment(@Nullable ElanInstance elanInstance) |
static org.opendaylight.infrautils.utils.concurrent.NamedSimpleReentrantLock.Acquired |
lockElanMacDPN(long elanTag,
String macAddress,
BigInteger dpnId) |
static <T extends org.opendaylight.yangtools.yang.binding.DataObject> |
read(@NonNull org.opendaylight.controller.md.sal.binding.api.DataBroker broker,
org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType,
org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path)
Deprecated.
Consider using
read2(LogicalDatastoreType, InstanceIdentifier) with proper exception
handling instead |
<T extends org.opendaylight.yangtools.yang.binding.DataObject> |
read2(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType,
org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path) |
static void |
releaseId(org.opendaylight.yang.gen.v1.urn.opendaylight.genius.idmanager.rev160406.IdManagerService idManager,
String poolName,
String idKey) |
void |
removeArpResponderFlow(BigInteger dpnId,
String ingressInterfaceName,
String ipAddress,
int lportTag) |
void |
removeDmacRedirectToDispatcherFlows(Long elanTag,
String macAddress,
List<BigInteger> dpnIds) |
void |
removeTerminatingServiceAction(BigInteger destDpId,
int serviceId) |
static Long |
retrieveNewElanTag(org.opendaylight.yang.gen.v1.urn.opendaylight.genius.idmanager.rev160406.IdManagerService idManager,
String idKey)
Uses the IdManager to retrieve a brand new ElanTag.
|
static List<com.google.common.util.concurrent.ListenableFuture<Void>> |
returnFailedListenableFutureIfTransactionCommitFailedExceptionCauseOrElseThrow(RuntimeException exception) |
void |
setupDMacFlowOnRemoteDpn(ElanInstance elanInfo,
org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo,
BigInteger dstDpId,
String macAddress,
org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> writeFlowTx) |
void |
setupMacFlows(ElanInstance elanInfo,
org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo,
long macTimeout,
String macAddress,
boolean configureRemoteFlows,
org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> writeFlowGroupTx)
Setting SMAC, DMAC, UDMAC in this DPN and optionally in other DPNs.
|
void |
setupRemoteDmacFlow(BigInteger srcDpId,
BigInteger destDpId,
int lportTag,
long elanTag,
String macAddress,
String displayName,
org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> writeFlowGroupTx,
String interfaceName,
ElanInstance elanInstance) |
void |
setupTermDmacFlows(org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo,
org.opendaylight.genius.mdsalutil.interfaces.IMdsalApiManager mdsalApiManager,
org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> writeFlowGroupTx)
Installs a Flow in INTERNAL_TUNNEL_TABLE of the affected DPN that sends
the packet through the specified interface if the tunnel_id matches the
interface's lportTag.
|
static ElanInstance |
updateOperationalDataStore(org.opendaylight.yang.gen.v1.urn.opendaylight.genius.idmanager.rev160406.IdManagerService idManager,
ElanInstance elanInstanceAdded,
List<String> elanInterfaces,
org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx,
org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Operational> operTx)
Updates the Elan information in the Operational DS.
|
static com.google.common.util.concurrent.ListenableFuture<Void> |
waitForTransactionToComplete(com.google.common.util.concurrent.ListenableFuture<Void> future) |
public static final com.google.common.util.concurrent.FutureCallback<Void> DEFAULT_CALLBACK
@Inject public ElanUtils(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker, org.opendaylight.genius.mdsalutil.interfaces.IMdsalApiManager mdsalManager, org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.rpcs.rev160406.OdlInterfaceRpcService interfaceManagerRpcService, org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.rpcs.rev160406.ItmRpcService itmRpcService, ElanConfig elanConfig, org.opendaylight.genius.interfacemanager.interfaces.IInterfaceManager interfaceManager, ElanEtreeUtils elanEtreeUtils, ElanItmUtils elanItmUtils, ElanInterfaceCache elanInterfaceCache, org.opendaylight.genius.itm.api.IITMProvider iitmProvider)
public final Boolean isOpenstackVniSemanticsEnforced()
public static Long retrieveNewElanTag(org.opendaylight.yang.gen.v1.urn.opendaylight.genius.idmanager.rev160406.IdManagerService idManager, String idKey)
idManager
- the id manageridKey
- the id keypublic static void releaseId(org.opendaylight.yang.gen.v1.urn.opendaylight.genius.idmanager.rev160406.IdManagerService idManager, String poolName, String idKey)
@Deprecated public static <T extends org.opendaylight.yangtools.yang.binding.DataObject> com.google.common.base.Optional<T> read(@NonNull org.opendaylight.controller.md.sal.binding.api.DataBroker broker, org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType, org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path)
read2(LogicalDatastoreType, InstanceIdentifier)
with proper exception
handling insteadT
- T extends DataObjectbroker
- dataBrokerdatastoreType
- Logical DataStore typepath
- IID to readpublic <T extends org.opendaylight.yangtools.yang.binding.DataObject> com.google.common.base.Optional<T> read2(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType, org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path) throws org.opendaylight.controller.md.sal.common.api.data.ReadFailedException
org.opendaylight.controller.md.sal.common.api.data.ReadFailedException
public static <T extends org.opendaylight.yangtools.yang.binding.DataObject> void delete(org.opendaylight.controller.md.sal.binding.api.DataBroker broker, org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType, org.opendaylight.yangtools.yang.binding.InstanceIdentifier<T> path)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ElanInterface> getElanInterfaceConfigurationDataPathId(String interfaceName)
public static @Nullable Elan getElanByName(org.opendaylight.controller.md.sal.binding.api.DataBroker broker, String elanInstanceName)
public static @Nullable Elan getElanByName(org.opendaylight.genius.infra.TypedReadTransaction<org.opendaylight.genius.infra.Datastore.Operational> tx, String elanInstanceName) throws ExecutionException, InterruptedException
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<Elan> getElanInstanceOperationalDataPath(String elanInstanceName)
public @Nullable MacEntry getInterfaceMacEntriesOperationalDataPath(String interfaceName, org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress)
public @Nullable MacEntry getInterfaceMacEntriesOperationalDataPathFromId(org.opendaylight.genius.infra.TypedReadTransaction<org.opendaylight.genius.infra.Datastore.Operational> tx, org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacEntry> identifier) throws ExecutionException, InterruptedException
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacEntry> getInterfaceMacEntriesIdentifierOperationalDataPath(String interfaceName, org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress)
public com.google.common.base.Optional<MacEntry> getMacEntryForElanInstance(String elanName, org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress)
public com.google.common.base.Optional<MacEntry> getMacEntryForElanInstance(org.opendaylight.genius.infra.TypedReadTransaction<org.opendaylight.genius.infra.Datastore.Operational> tx, String elanName, org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress) throws ExecutionException, InterruptedException
public @Nullable MacEntry getMacEntryFromElanMacId(org.opendaylight.genius.infra.TypedReadTransaction<org.opendaylight.genius.infra.Datastore.Operational> tx, org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacEntry> identifier) throws ExecutionException, InterruptedException
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacEntry> getMacEntryOperationalDataPath(String elanName, org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress physAddress)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<MacTable> getElanMacTableOperationalDataPath(String elanName)
public ElanInterfaceMac getElanInterfaceMacByInterfaceName(String interfaceName)
public static @Nullable ElanInterfaceMac getElanInterfaceMacByInterfaceName(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker, String interfaceName)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ElanInterfaceMac> getElanInterfaceMacEntriesOperationalDataPath(String interfaceName)
public @Nullable DpnInterfaces getElanInterfaceInfoByElanDpn(String elanInstanceName, BigInteger dpId)
elanInstanceName
- name of the Elan to which the interfaces must belong todpId
- Id of the DPN where the interfaces are locatedpublic static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<DpnInterfaces> getElanDpnInterfaceOperationalDataPath(String elanInstanceName, BigInteger dpId)
elanInstanceName
- name of the Elan to which the interfaces must belong todpId
- Id of the DPN where the interfaces are locatedpublic @Nullable ElanTagName getElanInfoByElanTag(long elanTag)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ElanTagName> getElanInfoEntriesOperationalDataPath(long elanTag)
public com.google.common.base.Optional<org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.meta.rev160406._if.indexes._interface.map.IfIndexInterface> getInterfaceInfoByInterfaceTag(long interfaceTag)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.meta.rev160406._if.indexes._interface.map.IfIndexInterface> getInterfaceInfoEntriesOperationalDataPath(long interfaceTag)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<ElanDpnInterfacesList> getElanDpnOperationDataPath(String elanInstanceName)
public @Nullable ElanDpnInterfacesList getElanDpnInterfacesList(String elanName)
public @Nullable ElanDpnInterfaces getElanDpnInterfacesList()
public @NonNull List<BigInteger> getParticipatingDpnsInElanInstance(String elanInstanceName)
elanInstanceName
- the elan instance namepublic static long getElanRemoteBroadCastGroupID(long elanTag)
public @Nullable MacTable getElanMacTable(String elanName)
elanName
- the elan namepublic static @Nullable MacTable getElanMacTable(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker, String elanName)
public static long getElanLocalBCGId(long elanTag)
public static long getElanRemoteBCGId(long elanTag)
public static long getEtreeLeafLocalBCGId(long etreeLeafTag)
public static long getEtreeLeafRemoteBCGId(long etreeLeafTag)
public static BigInteger getElanMetadataLabel(long elanTag, boolean isSHFlagSet)
public void setupMacFlows(ElanInstance elanInfo, org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo, long macTimeout, String macAddress, boolean configureRemoteFlows, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> writeFlowGroupTx)
elanInfo
- the elan infointerfaceInfo
- the interface infomacTimeout
- the mac timeoutmacAddress
- the mac addressconfigureRemoteFlows
- true if remote dmac flows should be configured as wellwriteFlowGroupTx
- the flow group txpublic void setupDMacFlowOnRemoteDpn(ElanInstance elanInfo, org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo, BigInteger dstDpId, String macAddress, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> writeFlowTx)
public org.opendaylight.genius.mdsalutil.FlowEntity buildKnownSmacFlow(ElanInstance elanInfo, org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo, long macTimeout, String macAddress)
public void setupTermDmacFlows(org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo, org.opendaylight.genius.mdsalutil.interfaces.IMdsalApiManager mdsalApiManager, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> writeFlowGroupTx)
interfaceInfo
- the interface infomdsalApiManager
- the mdsal API managerwriteFlowGroupTx
- the writeFLowGroup txpublic static String getIntTunnelTableFlowRef(short tableId, int elanTag)
tableId
- table IdelanTag
- elan Tagpublic static List<org.opendaylight.genius.mdsalutil.MatchInfo> getTunnelIdMatchForFilterEqualsLPortTag(int lportTag)
lportTag
- lportTag that must be checked against the tunnel_id fieldpublic List<org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.list.Instruction> getInstructionsInPortForOutGroup(String ifName)
ifName
- Name of the interface where the packet must be sent over. It
can be a local interface or a tunnel interface (internal or
external)public @NonNull List<org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.list.Action> getEgressActionsForInterface(String ifName, @Nullable Long tunnelKey)
ifName
- the if nametunnelKey
- the tunnel keypublic @NonNull List<DpnInterfaces> getInvolvedDpnsInElan(String elanName)
public @NonNull List<DpnInterfaces> getElanDPNByName(String elanInstanceName)
public static String getKnownDynamicmacFlowRef(short tableId, BigInteger dpId, long lporTag, String macAddress, long elanTag)
public static String getKnownDynamicmacFlowRef(short tableId, BigInteger dpId, BigInteger remoteDpId, String macAddress, long elanTag)
public static String getKnownDynamicmacFlowRef(short tableId, BigInteger dpId, String macAddress, long elanTag)
public static String getKnownDynamicmacFlowRef(short elanDmacTable, BigInteger dpId, String extDeviceNodeId, String dstMacAddress, long elanTag, boolean shFlag)
public org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.tables.table.Flow buildLocalDmacFlowEntry(long elanTag, BigInteger dpId, String ifName, String macAddress, ElanInstance elanInfo, long ifTag)
Match: + elanTag in metadata + packet goes to a MAC locally attached Actions: + optionally, pop-vlan + set-vlan-id + output to ifName's portNumber
elanTag
- the elan tagdpId
- the dp idifName
- the if namemacAddress
- the mac addresselanInfo
- the elan infoifTag
- the if tagpublic void setupRemoteDmacFlow(BigInteger srcDpId, BigInteger destDpId, int lportTag, long elanTag, String macAddress, String displayName, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> writeFlowGroupTx, String interfaceName, ElanInstance elanInstance)
public org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.tables.table.Flow buildRemoteDmacFlowEntry(BigInteger srcDpId, BigInteger destDpId, long lportTagOrVni, long elanTag, String macAddress, String displayName, ElanInstance elanInstance)
srcDpId
- the src Dpn IddestDpId
- dest Dp IdlportTagOrVni
- lportTag or network VNIelanTag
- elan TagmacAddress
- macAddressdisplayName
- display NameelanInstance
- elanInstancepublic void deleteMacFlows(@Nullable ElanInstance elanInfo, @Nullable org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo, MacEntry macEntry, org.opendaylight.genius.infra.TypedReadWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> flowTx) throws ExecutionException, InterruptedException
public void deleteMacFlows(ElanInstance elanInfo, org.opendaylight.genius.interfacemanager.globals.InterfaceInfo interfaceInfo, String macAddress, boolean deleteSmac, org.opendaylight.genius.infra.TypedReadWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> flowTx) throws ExecutionException, InterruptedException
public static ElanInstance updateOperationalDataStore(org.opendaylight.yang.gen.v1.urn.opendaylight.genius.idmanager.rev160406.IdManagerService idManager, ElanInstance elanInstanceAdded, List<String> elanInterfaces, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Configuration> confTx, org.opendaylight.genius.infra.TypedWriteTransaction<org.opendaylight.genius.infra.Datastore.Operational> operTx)
idManager
- the id managerelanInstanceAdded
- the elan instance addedelanInterfaces
- the elan interfacesoperTx
- transactionpublic boolean isDpnPresent(BigInteger dpnId)
public static org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.servicebinding.rev160406.service.bindings.services.info.BoundServices getBoundServices(String serviceName, short servicePriority, int flowPriority, BigInteger cookie, List<org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.list.Instruction> instructions)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.opendaylight.genius.interfacemanager.servicebinding.rev160406.service.bindings.services.info.BoundServices> buildServiceId(String interfaceName, short serviceIndex)
public static List<org.opendaylight.genius.mdsalutil.MatchInfo> getTunnelMatchesForServiceId(int elanTag)
public void removeTerminatingServiceAction(BigInteger destDpId, int serviceId)
public @Nullable org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.op.rev160406.external.tunnel.list.ExternalTunnel getExternalTunnel(String sourceDevice, String destinationDevice, org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType)
sourceDevice
- the source devicedestinationDevice
- the destination devicedatastoreType
- the datastore typepublic @Nullable org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.op.rev160406.external.tunnel.list.ExternalTunnel getExternalTunnel(String interfaceName, org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType)
interfaceName
- the interface namedatastoreType
- the datastore typepublic List<org.opendaylight.yang.gen.v1.urn.opendaylight.genius.itm.op.rev160406.external.tunnel.list.ExternalTunnel> getAllExternalTunnels(org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType datastoreType)
datastoreType
- the data store typepublic static List<org.opendaylight.genius.mdsalutil.MatchInfo> buildMatchesForElanTagShFlagAndDstMac(long elanTag, boolean shFlag, String macAddr)
public static boolean isInterfaceOperational(String interfaceName, org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker)
interfaceName
- the interface namedataBroker
- the data brokerpublic static org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.state.Interface getInterfaceStateFromOperDS(String interfaceName, org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker)
interfaceName
- the interface namedataBroker
- the data brokerpublic static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.state.Interface> createInterfaceStateInstanceIdentifier(String interfaceName)
interfaceName
- the interface name@CheckReturnValue public static com.google.common.util.concurrent.ListenableFuture<Void> waitForTransactionToComplete(com.google.common.util.concurrent.ListenableFuture<Void> future)
public static boolean isVxlan(@Nullable ElanInstance elanInstance)
public static boolean isVxlanNetworkOrVxlanSegment(@Nullable ElanInstance elanInstance)
public static Long getVxlanSegmentationId(ElanInstance elanInstance)
public static boolean isVlan(ElanInstance elanInstance)
public static boolean isFlat(ElanInstance elanInstance)
public void addDmacRedirectToDispatcherFlows(Long elanTag, String displayName, String macAddress, List<BigInteger> dpnIds)
public void removeDmacRedirectToDispatcherFlows(Long elanTag, String macAddress, List<BigInteger> dpnIds)
public static org.opendaylight.genius.mdsalutil.FlowEntity buildDmacRedirectToDispatcherFlow(BigInteger dpId, String dstMacAddress, String displayName, long elanTag)
public @Nullable String getExternalElanInterface(String elanInstanceName, BigInteger dpnId)
public static org.opendaylight.infrautils.utils.concurrent.NamedSimpleReentrantLock.Acquired lockElanMacDPN(long elanTag, String macAddress, BigInteger dpnId)
public static List<com.google.common.util.concurrent.ListenableFuture<Void>> returnFailedListenableFutureIfTransactionCommitFailedExceptionCauseOrElseThrow(RuntimeException exception)
public static List<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.PhysAddress> getPhysAddress(List<String> macAddress)
public static List<StaticMacEntries> getStaticMacEntries(List<String> staticMacAddresses)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<StaticMacEntries> getStaticMacEntriesCfgDataPathIdentifier(String interfaceName, String macAddress)
public static boolean isEmpty(Collection collection)
public static boolean isNotEmpty(Collection collection)
public com.google.common.base.Optional<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddress> getSourceIpAddress(org.opendaylight.genius.mdsalutil.packet.Ethernet ethernet)
public boolean isTunnelInLogicalGroup(String interfaceName)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.tables.table.Flow> getFlowIid(org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.tables.table.Flow flow, BigInteger dpnId)
public void removeArpResponderFlow(BigInteger dpnId, String ingressInterfaceName, String ipAddress, int lportTag)
public static @Nullable String getRouterPordIdFromElanInstance(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker, String elanInstanceName)
public static org.opendaylight.yangtools.yang.binding.InstanceIdentifier<org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.groups.Group> getGroupInstanceid(BigInteger dpnId, long groupId)
Copyright © 2020 OpenDaylight. All rights reserved.