AlivenessMonitorService alivenessMonitorService, DataBroker dataBroker, String interfaceName,
FlowCapableNodeConnector flowCapableNodeConnectorNew,
FlowCapableNodeConnector flowCapableNodeConnectorOld) {
- LOG.debug("Update of Interface State for port: {}", interfaceName);
+ LOG.debug("Updating interface state information for interface: {}", interfaceName);
List<ListenableFuture<Void>> futures = new ArrayList<>();
- Interface.OperStatus operStatusNew = getOpState(flowCapableNodeConnectorNew);
+ Interface.OperStatus operStatusNew = InterfaceManagerCommonUtils.getOpState(flowCapableNodeConnectorNew);
MacAddress macAddressNew = flowCapableNodeConnectorNew.getHardwareAddress();
- Interface.OperStatus operStatusOld = getOpState(flowCapableNodeConnectorOld);
+ Interface.OperStatus operStatusOld = InterfaceManagerCommonUtils.getOpState(flowCapableNodeConnectorOld);
MacAddress macAddressOld = flowCapableNodeConnectorOld.getHardwareAddress();
boolean opstateModified = false;
}
}
- public static Interface.OperStatus getOpState(FlowCapableNodeConnector flowCapableNodeConnector) {
- Interface.OperStatus operStatus = flowCapableNodeConnector.getState().isLive()
- && !flowCapableNodeConnector.getConfiguration().isPORTDOWN() ? Interface.OperStatus.Up
- : Interface.OperStatus.Down;
- return operStatus;
- }
-
public static void handleInterfaceStateUpdates(
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang
.ietf.interfaces.rev140508.interfaces.Interface iface,