import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;
import java.util.stream.Collectors;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;
import java.util.stream.Collectors;
import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.mdsal.binding.api.ReadTransaction;
import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
import org.opendaylight.mdsal.binding.api.DataBroker;
import org.opendaylight.mdsal.binding.api.ReadTransaction;
import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
if ((networkLinks == null) || networkLinks.isEmpty()) {
LOG.warn("Links are not present in {} topology.", NetworkUtils.OVERLAY_NETWORK_ID);
return Collections.emptyList();
}
if ((networkLinks == null) || networkLinks.isEmpty()) {
LOG.warn("Links are not present in {} topology.", NetworkUtils.OVERLAY_NETWORK_ID);
return Collections.emptyList();
}
openRoadmInterfaces.postInterface(realNodeId,interfaceBuilder);
LOG.info("Spanloss Value update completed successfully");
return true;
openRoadmInterfaces.postInterface(realNodeId,interfaceBuilder);
LOG.info("Spanloss Value update completed successfully");
return true;
- interfaceBuilder.addAugmentation(org.opendaylight.yang.gen.v1.http
- .org.openroadm.optical.transport.interfaces.rev181019.Interface1.class,
- intf1Builder.setOts(otsBuilder.build()).build());
+ interfaceBuilder.addAugmentation(intf1Builder.setOts(otsBuilder.build()).build());
openRoadmInterfaces.postInterface(realNodeId,interfaceBuilder);
LOG.info("Spanloss Value update completed successfully");
return true;
openRoadmInterfaces.postInterface(realNodeId,interfaceBuilder);
LOG.info("Spanloss Value update completed successfully");
return true;
* @return map with list of spans with their spanloss value
*/
private Map<LinkId, BigDecimal> getLinkSpanloss(List<RoadmLinks> roadmLinks) {
* @return map with list of spans with their spanloss value
*/
private Map<LinkId, BigDecimal> getLinkSpanloss(List<RoadmLinks> roadmLinks) {
.setScale(1, RoundingMode.HALF_UP);
LOG.info("Spanloss Calculated as :{}={}-{}",
spanLoss, srcOtsPmHoler.getOtsParameterVal(), destOtsPmHoler.getOtsParameterVal());
.setScale(1, RoundingMode.HALF_UP);
LOG.info("Spanloss Calculated as :{}={}-{}",
spanLoss, srcOtsPmHoler.getOtsParameterVal(), destOtsPmHoler.getOtsParameterVal());
throw new IllegalArgumentException(
String.format("Could not find node %s, or supporting node is not present", mappedNodeId));
}
throw new IllegalArgumentException(
String.format("Could not find node %s, or supporting node is not present", mappedNodeId));
}
.filter(node -> (node.getNetworkRef() != null)
&& NetworkUtils.UNDERLAY_NETWORK_ID.equals(node.getNetworkRef().getValue())
&& (node.getNodeRef() != null) && !Strings.isNullOrEmpty(node.getNodeRef().getValue()))
.filter(node -> (node.getNetworkRef() != null)
&& NetworkUtils.UNDERLAY_NETWORK_ID.equals(node.getNetworkRef().getValue())
&& (node.getNodeRef() != null) && !Strings.isNullOrEmpty(node.getNodeRef().getValue()))