Jonathan Hart

Remove SDN-IP TODOs

Change-Id: I59b510ba95d4f76600d23d79a81964c2ef290a56
......@@ -295,10 +295,6 @@ public class IntentSynchronizer {
routeIntents.put(prefix, intent);
if (isElectedLeader && isActivatedLeader) {
if (oldIntent != null) {
//
// TODO: Short-term solution to explicitly withdraw
// instead of using "replace" operation.
//
log.trace("SDN-IP Withdrawing old intent: {}",
oldIntent);
withdrawBuilder.addWithdrawOperation(oldIntent.id());
......@@ -390,7 +386,6 @@ public class IntentSynchronizer {
IPCriterion ipCriterion = (IPCriterion) c;
Ip4Prefix ip4Prefix = ipCriterion.ip().getIp4Prefix();
if (ip4Prefix == null) {
// TODO: For now we support only IPv4
continue;
}
log.trace("SDN-IP Intent Synchronizer: updating " +
......
......@@ -94,7 +94,6 @@ public class PeerConnectivityManager {
* Stops the peer connectivity manager.
*/
public void stop() {
// TODO: Implement it
}
/**
......
......@@ -29,6 +29,11 @@ import java.util.concurrent.Executors;
import java.util.concurrent.LinkedBlockingQueue;
import org.apache.commons.lang3.tuple.Pair;
import org.onlab.packet.Ethernet;
import org.onlab.packet.Ip4Address;
import org.onlab.packet.Ip4Prefix;
import org.onlab.packet.IpAddress;
import org.onlab.packet.MacAddress;
import org.onosproject.core.ApplicationId;
import org.onosproject.net.ConnectPoint;
import org.onosproject.net.Host;
......@@ -43,11 +48,6 @@ import org.onosproject.net.intent.MultiPointToSinglePointIntent;
import org.onosproject.sdnip.config.BgpPeer;
import org.onosproject.sdnip.config.Interface;
import org.onosproject.sdnip.config.SdnIpConfigurationService;
import org.onlab.packet.Ethernet;
import org.onlab.packet.IpAddress;
import org.onlab.packet.Ip4Address;
import org.onlab.packet.Ip4Prefix;
import org.onlab.packet.MacAddress;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
......@@ -294,7 +294,6 @@ public class Router implements RouteListener {
if (nextHopMacAddress == null) {
Set<Host> hosts = hostService.getHostsByIp(routeEntry.nextHop());
if (!hosts.isEmpty()) {
// TODO how to handle if multiple hosts are returned?
nextHopMacAddress = hosts.iterator().next().mac();
}
if (nextHopMacAddress != null) {
......@@ -406,7 +405,6 @@ public class Router implements RouteListener {
}
routesWaitingOnArp.remove(routeEntry.nextHop(), routeEntry);
// TODO cancel the request in the ARP manager as well
}
/**
......@@ -421,10 +419,6 @@ public class Router implements RouteListener {
private void updateMac(Ip4Address ipAddress, MacAddress macAddress) {
log.debug("Received updated MAC info: {} => {}", ipAddress, macAddress);
// TODO here we should check whether the next hop for any of our
// installed prefixes has changed, not just prefixes pending
// installation.
// We synchronize on this to prevent changes to the radix tree
// while we're pushing intents. If the tree changes, the
// tree and intents could get out of sync.
......@@ -505,7 +499,6 @@ public class Router implements RouteListener {
for (IpAddress ip : host.ipAddresses()) {
Ip4Address ip4Address = ip.getIp4Address();
if (ip4Address == null) {
// TODO: For now we support only IPv4
continue;
}
updateMac(ip4Address, host.mac());
......@@ -515,7 +508,6 @@ public class Router implements RouteListener {
for (IpAddress ip : host.ipAddresses()) {
Ip4Address ip4Address = ip.getIp4Address();
if (ip4Address == null) {
// TODO: For now we support only IPv4
continue;
}
ip2Mac.remove(ip4Address);
......
......@@ -115,8 +115,6 @@ public class SdnIp implements SdnIpService {
bgpSessionManager = new BgpSessionManager(router);
bgpSessionManager.start(bgpPort);
// TODO need to disable link discovery on external ports
}
@Deactivate
......
......@@ -36,8 +36,6 @@ public class SdnIpConfigurationReader implements SdnIpConfigurationService {
private final Logger log = LoggerFactory.getLogger(getClass());
// Current working dir seems to be /opt/onos/apache-karaf-3.0.2
// TODO: Set the path to /opt/onos/config
private static final String CONFIG_DIR = "../config";
private static final String DEFAULT_CONFIG_FILE = "sdnip.json";
private String configFileName = DEFAULT_CONFIG_FILE;
......
......@@ -678,8 +678,6 @@ public class PeerConnectivityManagerTest extends AbstractIntentTest {
/**
* Tests a corner case, when there is no Interface configured for one BGP
* speaker.
* TODO: we should add a configuration correctness checking module/method
* before testing this corner case.
*/
@Ignore
@Test
......