Committed by
Gerrit Code Review
removing some TODOs
Change-Id: Ic98c811573a1b37813993eedddec512ec85729f3
Showing
35 changed files
with
16 additions
and
93 deletions
... | @@ -58,7 +58,6 @@ public class ElectionTest { | ... | @@ -58,7 +58,6 @@ public class ElectionTest { |
58 | 58 | ||
59 | private ControllerNode localControllerNode; | 59 | private ControllerNode localControllerNode; |
60 | 60 | ||
61 | - // TODO write cli command to get leader | ||
62 | 61 | ||
63 | @Activate | 62 | @Activate |
64 | protected void activate() { | 63 | protected void activate() { | ... | ... |
... | @@ -174,7 +174,6 @@ public class FooComponent { | ... | @@ -174,7 +174,6 @@ public class FooComponent { |
174 | //try { | 174 | //try { |
175 | //Thread.sleep(5000); | 175 | //Thread.sleep(5000); |
176 | //} catch (InterruptedException e) { | 176 | //} catch (InterruptedException e) { |
177 | - // TODO Auto-generated catch block | ||
178 | //e.printStackTrace(); | 177 | //e.printStackTrace(); |
179 | //} | 178 | //} |
180 | log.info("Acquired Lock"); | 179 | log.info("Acquired Lock"); | ... | ... |
... | @@ -129,10 +129,6 @@ public class IntentMetrics implements IntentMetricsService, | ... | @@ -129,10 +129,6 @@ public class IntentMetrics implements IntentMetricsService, |
129 | @Override | 129 | @Override |
130 | public void event(IntentEvent event) { | 130 | public void event(IntentEvent event) { |
131 | synchronized (lastEvents) { | 131 | synchronized (lastEvents) { |
132 | - // | ||
133 | - // TODO: The processing below is incomplete: we don't have | ||
134 | - // an event equivalent of "Withdraw Requested" | ||
135 | - // | ||
136 | switch (event.type()) { | 132 | switch (event.type()) { |
137 | case INSTALL_REQ: | 133 | case INSTALL_REQ: |
138 | intentSubmittedEventMetric.eventReceived(); | 134 | intentSubmittedEventMetric.eventReceived(); |
... | @@ -141,7 +137,7 @@ public class IntentMetrics implements IntentMetricsService, | ... | @@ -141,7 +137,7 @@ public class IntentMetrics implements IntentMetricsService, |
141 | intentInstalledEventMetric.eventReceived(); | 137 | intentInstalledEventMetric.eventReceived(); |
142 | break; | 138 | break; |
143 | case FAILED: | 139 | case FAILED: |
144 | - // TODO: Just ignore? | 140 | + // ignore |
145 | break; | 141 | break; |
146 | case WITHDRAW_REQ: | 142 | case WITHDRAW_REQ: |
147 | intentWithdrawRequestedEventMetric.eventReceived(); | 143 | intentWithdrawRequestedEventMetric.eventReceived(); | ... | ... |
... | @@ -364,7 +364,6 @@ public class OpticalConfigProvider extends AbstractProvider implements DevicePro | ... | @@ -364,7 +364,6 @@ public class OpticalConfigProvider extends AbstractProvider implements DevicePro |
364 | 364 | ||
365 | @Override | 365 | @Override |
366 | public void roleChanged(DeviceId device, MastershipRole newRole) { | 366 | public void roleChanged(DeviceId device, MastershipRole newRole) { |
367 | - // TODO Auto-generated method stub. | ||
368 | } | 367 | } |
369 | 368 | ||
370 | @Override | 369 | @Override | ... | ... |
... | @@ -36,7 +36,6 @@ class PktOptLink { | ... | @@ -36,7 +36,6 @@ class PktOptLink { |
36 | } | 36 | } |
37 | 37 | ||
38 | public PktOptLink() { | 38 | public PktOptLink() { |
39 | - // TODO Auto-generated constructor stub | ||
40 | } | 39 | } |
41 | 40 | ||
42 | public void setSrcNodeName(String name) { | 41 | public void setSrcNodeName(String name) { | ... | ... |
... | @@ -49,13 +49,11 @@ public class MetricsListCommand extends AbstractShellCommand { | ... | @@ -49,13 +49,11 @@ public class MetricsListCommand extends AbstractShellCommand { |
49 | protected void execute() { | 49 | protected void execute() { |
50 | MetricsService metricsService = get(MetricsService.class); | 50 | MetricsService metricsService = get(MetricsService.class); |
51 | 51 | ||
52 | - // TODO support filter condition | ||
53 | MetricFilter filter = MetricFilter.ALL; | 52 | MetricFilter filter = MetricFilter.ALL; |
54 | 53 | ||
55 | TreeMultimap<String, Metric> matched = listMetrics(metricsService, filter); | 54 | TreeMultimap<String, Metric> matched = listMetrics(metricsService, filter); |
56 | matched.asMap().forEach((name, metrics) -> { | 55 | matched.asMap().forEach((name, metrics) -> { |
57 | for (Metric metric : metrics) { | 56 | for (Metric metric : metrics) { |
58 | - // TODO JSON version | ||
59 | printMetric(name, metric); | 57 | printMetric(name, metric); |
60 | } | 58 | } |
61 | }); | 59 | }); | ... | ... |
... | @@ -17,11 +17,11 @@ package org.onosproject.cli; | ... | @@ -17,11 +17,11 @@ package org.onosproject.cli; |
17 | 17 | ||
18 | import org.apache.karaf.shell.commands.Argument; | 18 | import org.apache.karaf.shell.commands.Argument; |
19 | import org.apache.karaf.shell.commands.Command; | 19 | import org.apache.karaf.shell.commands.Command; |
20 | +import org.onlab.packet.IpAddress; | ||
20 | import org.onosproject.cluster.ControllerNode; | 21 | import org.onosproject.cluster.ControllerNode; |
21 | import org.onosproject.cluster.DefaultControllerNode; | 22 | import org.onosproject.cluster.DefaultControllerNode; |
22 | import org.onosproject.cluster.NodeId; | 23 | import org.onosproject.cluster.NodeId; |
23 | import org.onosproject.store.service.DatabaseAdminService; | 24 | import org.onosproject.store.service.DatabaseAdminService; |
24 | -import org.onlab.packet.IpAddress; | ||
25 | 25 | ||
26 | /** | 26 | /** |
27 | * Adds a new controller cluster node. | 27 | * Adds a new controller cluster node. |
... | @@ -34,7 +34,6 @@ public class TabletAddCommand extends AbstractShellCommand { | ... | @@ -34,7 +34,6 @@ public class TabletAddCommand extends AbstractShellCommand { |
34 | required = true, multiValued = false) | 34 | required = true, multiValued = false) |
35 | String nodeId = null; | 35 | String nodeId = null; |
36 | 36 | ||
37 | - // TODO context aware completer to get IP from ClusterService? | ||
38 | @Argument(index = 1, name = "ip", description = "Node IP address", | 37 | @Argument(index = 1, name = "ip", description = "Node IP address", |
39 | required = true, multiValued = false) | 38 | required = true, multiValued = false) |
40 | String ip = null; | 39 | String ip = null; | ... | ... |
... | @@ -30,7 +30,6 @@ import org.onosproject.net.topology.TopologyService; | ... | @@ -30,7 +30,6 @@ import org.onosproject.net.topology.TopologyService; |
30 | description = "Lists summary of the current topology") | 30 | description = "Lists summary of the current topology") |
31 | public class TopologyCommand extends AbstractShellCommand { | 31 | public class TopologyCommand extends AbstractShellCommand { |
32 | 32 | ||
33 | - // TODO: format the time-stamp | ||
34 | private static final String FMT = | 33 | private static final String FMT = |
35 | "time=%s, devices=%d, links=%d, clusters=%d, paths=%d"; | 34 | "time=%s, devices=%d, links=%d, clusters=%d, paths=%d"; |
36 | 35 | ... | ... |
... | @@ -51,7 +51,6 @@ public class DefaultEventSinkRegistry implements EventSinkRegistry { | ... | @@ -51,7 +51,6 @@ public class DefaultEventSinkRegistry implements EventSinkRegistry { |
51 | @Override | 51 | @Override |
52 | @SuppressWarnings("unchecked") | 52 | @SuppressWarnings("unchecked") |
53 | public <E extends Event> EventSink<E> getSink(Class<E> eventClass) { | 53 | public <E extends Event> EventSink<E> getSink(Class<E> eventClass) { |
54 | - // TODO: add implicit registration of descendant classes | ||
55 | return (EventSink<E>) sinks.get(eventClass); | 54 | return (EventSink<E>) sinks.get(eventClass); |
56 | } | 55 | } |
57 | 56 | ... | ... |
... | @@ -296,7 +296,6 @@ public class MastershipManager | ... | @@ -296,7 +296,6 @@ public class MastershipManager |
296 | @Override | 296 | @Override |
297 | public void event(ClusterEvent event) { | 297 | public void event(ClusterEvent event) { |
298 | switch (event.type()) { | 298 | switch (event.type()) { |
299 | - //FIXME: worry about addition when the time comes | ||
300 | case INSTANCE_ADDED: | 299 | case INSTANCE_ADDED: |
301 | case INSTANCE_ACTIVATED: | 300 | case INSTANCE_ACTIVATED: |
302 | clusterSize.incrementAndGet(); | 301 | clusterSize.incrementAndGet(); |
... | @@ -341,14 +340,9 @@ public class MastershipManager | ... | @@ -341,14 +340,9 @@ public class MastershipManager |
341 | if (clusterService.getNodes().size() > (clusterSize.intValue() / 2)) { | 340 | if (clusterService.getNodes().size() > (clusterSize.intValue() / 2)) { |
342 | return true; | 341 | return true; |
343 | } | 342 | } |
344 | -// else { | ||
345 | - //FIXME: break tie for equal-sized clusters, by number of | ||
346 | - // connected switches, then masters, then nodeId hash | ||
347 | - // problem is, how do we get at channel info cleanly here? | ||
348 | - // Also, what's the time hit for a distributed store look-up | ||
349 | - // versus channel re-negotiation? bet on the latter being worse. | ||
350 | 343 | ||
351 | -// } | 344 | + //FIXME: break tie for equal-sized clusters, |
345 | + | ||
352 | return false; | 346 | return false; |
353 | } | 347 | } |
354 | 348 | ... | ... |
... | @@ -81,7 +81,6 @@ public class CoreManager implements CoreService { | ... | @@ -81,7 +81,6 @@ public class CoreManager implements CoreService { |
81 | 81 | ||
82 | @Override | 82 | @Override |
83 | public IdGenerator getIdGenerator(String topic) { | 83 | public IdGenerator getIdGenerator(String topic) { |
84 | - // FIXME this should be created lazily (once per topic) | ||
85 | IdBlockAllocator allocator = new StoreBasedIdBlockAllocator(topic, idBlockStore); | 84 | IdBlockAllocator allocator = new StoreBasedIdBlockAllocator(topic, idBlockStore); |
86 | return new BlockAllocatorBasedIdGenerator(allocator); | 85 | return new BlockAllocatorBasedIdGenerator(allocator); |
87 | } | 86 | } | ... | ... |
... | @@ -26,8 +26,6 @@ import org.projectfloodlight.openflow.types.OFPort; | ... | @@ -26,8 +26,6 @@ import org.projectfloodlight.openflow.types.OFPort; |
26 | */ | 26 | */ |
27 | public interface OpenFlowPacketContext { | 27 | public interface OpenFlowPacketContext { |
28 | 28 | ||
29 | - //TODO: may want to support sending packet out other switches than | ||
30 | - // the one it came in on. | ||
31 | /** | 29 | /** |
32 | * Blocks further responses (ie. send() calls) on this | 30 | * Blocks further responses (ie. send() calls) on this |
33 | * packet in event. | 31 | * packet in event. | ... | ... |
... | @@ -275,8 +275,8 @@ public abstract class AbstractOpenFlowSwitch implements OpenFlowSwitchDriver { | ... | @@ -275,8 +275,8 @@ public abstract class AbstractOpenFlowSwitch implements OpenFlowSwitchDriver { |
275 | this.transitionToEqualSwitch(); | 275 | this.transitionToEqualSwitch(); |
276 | } | 276 | } |
277 | } else { | 277 | } else { |
278 | + log.warn("Failed to set role for {}", this.getStringId()); | ||
278 | return; | 279 | return; |
279 | - //TODO: tell people that we failed. | ||
280 | } | 280 | } |
281 | } | 281 | } |
282 | 282 | ... | ... |
... | @@ -81,13 +81,9 @@ public class OpenflowControllerAdapter implements OpenFlowController { | ... | @@ -81,13 +81,9 @@ public class OpenflowControllerAdapter implements OpenFlowController { |
81 | 81 | ||
82 | @Override | 82 | @Override |
83 | public void addEventListener(OpenFlowEventListener listener) { | 83 | public void addEventListener(OpenFlowEventListener listener) { |
84 | - // TODO Auto-generated method stub | ||
85 | - | ||
86 | } | 84 | } |
87 | 85 | ||
88 | @Override | 86 | @Override |
89 | public void removeEventListener(OpenFlowEventListener listener) { | 87 | public void removeEventListener(OpenFlowEventListener listener) { |
90 | - // TODO Auto-generated method stub | ||
91 | - | ||
92 | } | 88 | } |
93 | } | 89 | } | ... | ... |
... | @@ -137,7 +137,6 @@ public class OFOpticalSwitchImplLINC13 extends AbstractOpenFlowSwitch { | ... | @@ -137,7 +137,6 @@ public class OFOpticalSwitchImplLINC13 extends AbstractOpenFlowSwitch { |
137 | } | 137 | } |
138 | } | 138 | } |
139 | 139 | ||
140 | - //Todo | ||
141 | public void processOFPortStatus(OFCircuitPortStatus ps) { | 140 | public void processOFPortStatus(OFCircuitPortStatus ps) { |
142 | log.debug("LINC-OE ..OF Port Status :", ps); | 141 | log.debug("LINC-OE ..OF Port Status :", ps); |
143 | 142 | ... | ... |
... | @@ -672,9 +672,7 @@ public class OFSwitchImplCPqD13 extends AbstractOpenFlowSwitch { | ... | @@ -672,9 +672,7 @@ public class OFSwitchImplCPqD13 extends AbstractOpenFlowSwitch { |
672 | subnetIps.add("10.0.3.0"); | 672 | subnetIps.add("10.0.3.0"); |
673 | subnetIps.add("10.0.1.0"); | 673 | subnetIps.add("10.0.1.0"); |
674 | } | 674 | } |
675 | - // TODO needed? | 675 | + |
676 | - //if (getId() == 0x2) { | ||
677 | - //} | ||
678 | if (getId() == 0x3) { | 676 | if (getId() == 0x3) { |
679 | subnetIps.add("7.7.7.0"); | 677 | subnetIps.add("7.7.7.0"); |
680 | } | 678 | } |
... | @@ -740,9 +738,6 @@ public class OFSwitchImplCPqD13 extends AbstractOpenFlowSwitch { | ... | @@ -740,9 +738,6 @@ public class OFSwitchImplCPqD13 extends AbstractOpenFlowSwitch { |
740 | hostNextHopIps.add(new RouteEntry("10.0.2.1", 4, "00:00:00:00:02:01")); | 738 | hostNextHopIps.add(new RouteEntry("10.0.2.1", 4, "00:00:00:00:02:01")); |
741 | hostNextHopIps.add(new RouteEntry("10.0.3.1", 5, "00:00:00:00:03:01")); | 739 | hostNextHopIps.add(new RouteEntry("10.0.3.1", 5, "00:00:00:00:03:01")); |
742 | } | 740 | } |
743 | - // TODO needed? | ||
744 | - //if (getId() == 0x2) { | ||
745 | - //} | ||
746 | if (getId() == 0x3) { | 741 | if (getId() == 0x3) { |
747 | hostNextHopIps.add(new RouteEntry("7.7.7.7", 1, "00:00:07:07:07:07")); | 742 | hostNextHopIps.add(new RouteEntry("7.7.7.7", 1, "00:00:07:07:07:07")); |
748 | } | 743 | } | ... | ... |
... | @@ -152,7 +152,7 @@ public class LLDPLinkProvider extends AbstractProvider implements LinkProvider { | ... | @@ -152,7 +152,7 @@ public class LLDPLinkProvider extends AbstractProvider implements LinkProvider { |
152 | } | 152 | } |
153 | synchronized (discoverers) { | 153 | synchronized (discoverers) { |
154 | if (!discoverers.containsKey(deviceId)) { | 154 | if (!discoverers.containsKey(deviceId)) { |
155 | - // TODO: ideally, should never reach here | 155 | + // ideally, should never reach here |
156 | log.debug("Device mastership changed ({}) {}", | 156 | log.debug("Device mastership changed ({}) {}", |
157 | event.type(), deviceId); | 157 | event.type(), deviceId); |
158 | discoverers.put(deviceId, new LinkDiscovery(device, | 158 | discoverers.put(deviceId, new LinkDiscovery(device, |
... | @@ -220,7 +220,7 @@ public class LLDPLinkProvider extends AbstractProvider implements LinkProvider { | ... | @@ -220,7 +220,7 @@ public class LLDPLinkProvider extends AbstractProvider implements LinkProvider { |
220 | ConnectPoint point = new ConnectPoint(deviceId, | 220 | ConnectPoint point = new ConnectPoint(deviceId, |
221 | port.number()); | 221 | port.number()); |
222 | providerService.linksVanished(point); | 222 | providerService.linksVanished(point); |
223 | - // TODO: Don't we need to removePort from ld? | 223 | + |
224 | break; | 224 | break; |
225 | case DEVICE_REMOVED: | 225 | case DEVICE_REMOVED: |
226 | case DEVICE_SUSPENDED: | 226 | case DEVICE_SUSPENDED: | ... | ... |
... | @@ -344,7 +344,6 @@ public class LinkDiscovery implements TimerTask { | ... | @@ -344,7 +344,6 @@ public class LinkDiscovery implements TimerTask { |
344 | } | 344 | } |
345 | 345 | ||
346 | private void sendProbes(Long portNumber) { | 346 | private void sendProbes(Long portNumber) { |
347 | - // TODO: should have suppression port configuration, not by type | ||
348 | if (device.type() != Device.Type.ROADM) { | 347 | if (device.type() != Device.Type.ROADM) { |
349 | log.trace("Sending probes out to {}@{}", portNumber, device.id()); | 348 | log.trace("Sending probes out to {}@{}", portNumber, device.id()); |
350 | OutboundPacket pkt = this.createOutBoundLLDP(portNumber); | 349 | OutboundPacket pkt = this.createOutBoundLLDP(portNumber); | ... | ... |
... | @@ -271,8 +271,6 @@ public class LLDPLinkProviderTest { | ... | @@ -271,8 +271,6 @@ public class LLDPLinkProviderTest { |
271 | 271 | ||
272 | @Override | 272 | @Override |
273 | public void linkVanished(LinkDescription linkDescription) { | 273 | public void linkVanished(LinkDescription linkDescription) { |
274 | - // TODO Auto-generated method stub | ||
275 | - | ||
276 | } | 274 | } |
277 | 275 | ||
278 | @Override | 276 | @Override | ... | ... |
... | @@ -137,18 +137,6 @@ public class OpenFlowDeviceProvider extends AbstractProvider implements DevicePr | ... | @@ -137,18 +137,6 @@ public class OpenFlowDeviceProvider extends AbstractProvider implements DevicePr |
137 | providerService.deviceDisconnected(deviceId); | 137 | providerService.deviceDisconnected(deviceId); |
138 | } else { | 138 | } else { |
139 | LOG.trace("Confirmed device {} connection", deviceId); | 139 | LOG.trace("Confirmed device {} connection", deviceId); |
140 | - // FIXME require something like below to match javadoc description | ||
141 | - // but this starts infinite loop with current DeviceManager | ||
142 | -// final ChassisId cId = new ChassisId(dpid.value()); | ||
143 | -// final Type deviceType = device.type(); | ||
144 | -// DeviceDescription description = | ||
145 | -// new DefaultDeviceDescription(deviceId.uri(), deviceType, | ||
146 | -// sw.manfacturerDescription(), | ||
147 | -// sw.hardwareDescription(), | ||
148 | -// sw.softwareDescription(), | ||
149 | -// sw.serialNumber(), | ||
150 | -// cId); | ||
151 | -// providerService.deviceConnected(deviceId, description); | ||
152 | } | 140 | } |
153 | 141 | ||
154 | // Prompt an update of port information. We can use any XID for this. | 142 | // Prompt an update of port information. We can use any XID for this. |
... | @@ -165,16 +153,6 @@ public class OpenFlowDeviceProvider extends AbstractProvider implements DevicePr | ... | @@ -165,16 +153,6 @@ public class OpenFlowDeviceProvider extends AbstractProvider implements DevicePr |
165 | } | 153 | } |
166 | } | 154 | } |
167 | 155 | ||
168 | - // Checks if the OF channel is connected. | ||
169 | - //private boolean checkChannel(Device device, OpenFlowSwitch sw) { | ||
170 | - // FIXME if possible, we might want this to be part of | ||
171 | - // OpenFlowSwitch interface so the driver interface isn't misused. | ||
172 | - // if (sw == null || !((OpenFlowSwitchDriver) sw).isConnected()) { | ||
173 | - // return false; | ||
174 | - // } | ||
175 | - // return true; | ||
176 | - // } | ||
177 | - | ||
178 | @Override | 156 | @Override |
179 | public void roleChanged(DeviceId deviceId, MastershipRole newRole) { | 157 | public void roleChanged(DeviceId deviceId, MastershipRole newRole) { |
180 | switch (newRole) { | 158 | switch (newRole) { | ... | ... |
... | @@ -186,7 +186,6 @@ public class FlowEntryBuilder { | ... | @@ -186,7 +186,6 @@ public class FlowEntryBuilder { |
186 | } | 186 | } |
187 | break; | 187 | break; |
188 | case SET_FIELD: | 188 | case SET_FIELD: |
189 | - // TODO handle 1.3 set field actions correctly | ||
190 | break; | 189 | break; |
191 | case SET_TP_DST: | 190 | case SET_TP_DST: |
192 | case SET_TP_SRC: | 191 | case SET_TP_SRC: | ... | ... |
providers/openflow/flow/src/main/java/org/onosproject/provider/of/flow/impl/FlowModBuilderVer10.java
... | @@ -78,7 +78,7 @@ public class FlowModBuilderVer10 extends FlowModBuilder { | ... | @@ -78,7 +78,7 @@ public class FlowModBuilderVer10 extends FlowModBuilder { |
78 | 78 | ||
79 | long cookie = flowRule().id().value(); | 79 | long cookie = flowRule().id().value(); |
80 | 80 | ||
81 | - //TODO: what to do without bufferid? do we assume that there will be a pktout as well? | 81 | + |
82 | OFFlowAdd fm = factory().buildFlowAdd() | 82 | OFFlowAdd fm = factory().buildFlowAdd() |
83 | .setXid(xid) | 83 | .setXid(xid) |
84 | .setCookie(U64.of(cookie)) | 84 | .setCookie(U64.of(cookie)) |
... | @@ -99,7 +99,7 @@ public class FlowModBuilderVer10 extends FlowModBuilder { | ... | @@ -99,7 +99,7 @@ public class FlowModBuilderVer10 extends FlowModBuilder { |
99 | 99 | ||
100 | long cookie = flowRule().id().value(); | 100 | long cookie = flowRule().id().value(); |
101 | 101 | ||
102 | - //TODO: what to do without bufferid? do we assume that there will be a pktout as well? | 102 | + |
103 | OFFlowMod fm = factory().buildFlowModify() | 103 | OFFlowMod fm = factory().buildFlowModify() |
104 | .setXid(xid) | 104 | .setXid(xid) |
105 | .setCookie(U64.of(cookie)) | 105 | .setCookie(U64.of(cookie)) | ... | ... |
providers/openflow/flow/src/main/java/org/onosproject/provider/of/flow/impl/FlowModBuilderVer13.java
... | @@ -93,7 +93,7 @@ public class FlowModBuilderVer13 extends FlowModBuilder { | ... | @@ -93,7 +93,7 @@ public class FlowModBuilderVer13 extends FlowModBuilder { |
93 | 93 | ||
94 | long cookie = flowRule().id().value(); | 94 | long cookie = flowRule().id().value(); |
95 | 95 | ||
96 | - //TODO: what to do without bufferid? do we assume that there will be a pktout as well? | 96 | + |
97 | OFFlowAdd fm = factory().buildFlowAdd() | 97 | OFFlowAdd fm = factory().buildFlowAdd() |
98 | .setXid(xid) | 98 | .setXid(xid) |
99 | .setCookie(U64.of(cookie)) | 99 | .setCookie(U64.of(cookie)) |
... | @@ -117,7 +117,7 @@ public class FlowModBuilderVer13 extends FlowModBuilder { | ... | @@ -117,7 +117,7 @@ public class FlowModBuilderVer13 extends FlowModBuilder { |
117 | 117 | ||
118 | long cookie = flowRule().id().value(); | 118 | long cookie = flowRule().id().value(); |
119 | 119 | ||
120 | - //TODO: what to do without bufferid? do we assume that there will be a pktout as well? | 120 | + |
121 | OFFlowMod fm = factory().buildFlowModify() | 121 | OFFlowMod fm = factory().buildFlowModify() |
122 | .setXid(xid) | 122 | .setXid(xid) |
123 | .setCookie(U64.of(cookie)) | 123 | .setCookie(U64.of(cookie)) |
... | @@ -145,8 +145,6 @@ public class FlowModBuilderVer13 extends FlowModBuilder { | ... | @@ -145,8 +145,6 @@ public class FlowModBuilderVer13 extends FlowModBuilder { |
145 | .setXid(xid) | 145 | .setXid(xid) |
146 | .setCookie(U64.of(cookie)) | 146 | .setCookie(U64.of(cookie)) |
147 | .setBufferId(OFBufferId.NO_BUFFER) | 147 | .setBufferId(OFBufferId.NO_BUFFER) |
148 | - //.setActions(actions) //FIXME do we want to send actions in flowdel? | ||
149 | - //.setInstructions(Collections.singletonList(writeActions)) | ||
150 | .setMatch(match) | 148 | .setMatch(match) |
151 | .setFlags(Collections.singleton(OFFlowModFlags.SEND_FLOW_REM)) | 149 | .setFlags(Collections.singleton(OFFlowModFlags.SEND_FLOW_REM)) |
152 | .setPriority(flowRule().priority()) | 150 | .setPriority(flowRule().priority()) | ... | ... |
... | @@ -142,7 +142,6 @@ public class OpenFlowHostProvider extends AbstractProvider implements HostProvid | ... | @@ -142,7 +142,6 @@ public class OpenFlowHostProvider extends AbstractProvider implements HostProvid |
142 | 142 | ||
143 | } | 143 | } |
144 | 144 | ||
145 | - // TODO: Use DHCP packets as well later... | ||
146 | } | 145 | } |
147 | 146 | ||
148 | } | 147 | } | ... | ... |
... | @@ -258,8 +258,6 @@ public class OpenFlowLinkProviderTest { | ... | @@ -258,8 +258,6 @@ public class OpenFlowLinkProviderTest { |
258 | 258 | ||
259 | @Override | 259 | @Override |
260 | public void linkVanished(LinkDescription linkDescription) { | 260 | public void linkVanished(LinkDescription linkDescription) { |
261 | - // TODO Auto-generated method stub | ||
262 | - | ||
263 | } | 261 | } |
264 | 262 | ||
265 | @Override | 263 | @Override | ... | ... |
... | @@ -111,7 +111,6 @@ implements MutableGraph<V, E> { | ... | @@ -111,7 +111,6 @@ implements MutableGraph<V, E> { |
111 | 111 | ||
112 | @Override | 112 | @Override |
113 | public void removeVertex(V vertex) { | 113 | public void removeVertex(V vertex) { |
114 | - // TODO Auto-generated method stub | ||
115 | if (vertexes != null && edges != null) { | 114 | if (vertexes != null && edges != null) { |
116 | if (vertexes.contains(vertex)) { | 115 | if (vertexes.contains(vertex)) { |
117 | vertexes.remove(vertex); | 116 | vertexes.remove(vertex); |
... | @@ -149,7 +148,6 @@ implements MutableGraph<V, E> { | ... | @@ -149,7 +148,6 @@ implements MutableGraph<V, E> { |
149 | 148 | ||
150 | @Override | 149 | @Override |
151 | public Graph<V, E> toImmutable() { | 150 | public Graph<V, E> toImmutable() { |
152 | - // TODO Auto-generated method stub | ||
153 | return null; | 151 | return null; |
154 | } | 152 | } |
155 | 153 | ... | ... |
... | @@ -118,9 +118,7 @@ public abstract class BasePacket implements IPacket { | ... | @@ -118,9 +118,7 @@ public abstract class BasePacket implements IPacket { |
118 | } catch (final Exception e) { | 118 | } catch (final Exception e) { |
119 | throw new RuntimeException("Could not clone packet"); | 119 | throw new RuntimeException("Could not clone packet"); |
120 | } | 120 | } |
121 | - // TODO: we are using serialize()/deserialize() to perform the | 121 | + |
122 | - // cloning. Not the most efficient way but simple. We can revisit | ||
123 | - // if we hit performance problems. | ||
124 | final byte[] data = this.serialize(); | 122 | final byte[] data = this.serialize(); |
125 | pkt.deserialize(this.serialize(), 0, data.length); | 123 | pkt.deserialize(this.serialize(), 0, data.length); |
126 | pkt.setParent(this.parent); | 124 | pkt.setParent(this.parent); | ... | ... |
... | @@ -19,7 +19,6 @@ package org.onlab.packet; | ... | @@ -19,7 +19,6 @@ package org.onlab.packet; |
19 | * The class representing a network device chassisId. | 19 | * The class representing a network device chassisId. |
20 | * This class is immutable. | 20 | * This class is immutable. |
21 | */ | 21 | */ |
22 | -// TODO: Move this to a reasonable place. | ||
23 | public final class ChassisId { | 22 | public final class ChassisId { |
24 | 23 | ||
25 | private static final long UNKNOWN = 0; | 24 | private static final long UNKNOWN = 0; | ... | ... |
... | @@ -262,7 +262,6 @@ public class IpAddress implements Comparable<IpAddress> { | ... | @@ -262,7 +262,6 @@ public class IpAddress implements Comparable<IpAddress> { |
262 | */ | 262 | */ |
263 | public static IpAddress makeMaskedAddress(final IpAddress address, | 263 | public static IpAddress makeMaskedAddress(final IpAddress address, |
264 | int prefixLength) { | 264 | int prefixLength) { |
265 | - // TODO: The code below should go away and replaced with generics | ||
266 | if (address instanceof Ip4Address) { | 265 | if (address instanceof Ip4Address) { |
267 | Ip4Address ip4a = (Ip4Address) address; | 266 | Ip4Address ip4a = (Ip4Address) address; |
268 | return Ip4Address.makeMaskedAddress(ip4a, prefixLength); | 267 | return Ip4Address.makeMaskedAddress(ip4a, prefixLength); | ... | ... |
... | @@ -86,7 +86,6 @@ public class NettyMessagingService implements MessagingService { | ... | @@ -86,7 +86,6 @@ public class NettyMessagingService implements MessagingService { |
86 | 86 | ||
87 | private void initEventLoopGroup() { | 87 | private void initEventLoopGroup() { |
88 | // try Epoll first and if that does work, use nio. | 88 | // try Epoll first and if that does work, use nio. |
89 | - // TODO: make this configurable. | ||
90 | try { | 89 | try { |
91 | clientGroup = new EpollEventLoopGroup(); | 90 | clientGroup = new EpollEventLoopGroup(); |
92 | serverGroup = new EpollEventLoopGroup(); | 91 | serverGroup = new EpollEventLoopGroup(); |
... | @@ -107,11 +106,9 @@ public class NettyMessagingService implements MessagingService { | ... | @@ -107,11 +106,9 @@ public class NettyMessagingService implements MessagingService { |
107 | } | 106 | } |
108 | 107 | ||
109 | public NettyMessagingService() { | 108 | public NettyMessagingService() { |
110 | - // TODO: Default port should be configurable. | ||
111 | this(8080); | 109 | this(8080); |
112 | } | 110 | } |
113 | 111 | ||
114 | - // FIXME: Constructor should not throw exceptions. | ||
115 | public NettyMessagingService(int port) { | 112 | public NettyMessagingService(int port) { |
116 | try { | 113 | try { |
117 | localEp = new Endpoint(java.net.InetAddress.getLocalHost().getHostName(), port); | 114 | localEp = new Endpoint(java.net.InetAddress.getLocalHost().getHostName(), port); |
... | @@ -193,7 +190,6 @@ public class NettyMessagingService implements MessagingService { | ... | @@ -193,7 +190,6 @@ public class NettyMessagingService implements MessagingService { |
193 | 190 | ||
194 | @Override | 191 | @Override |
195 | public void registerHandler(String type, MessageHandler handler) { | 192 | public void registerHandler(String type, MessageHandler handler) { |
196 | - // TODO: Is this the right semantics for handler registration? | ||
197 | handlers.putIfAbsent(type, handler); | 193 | handlers.putIfAbsent(type, handler); |
198 | } | 194 | } |
199 | 195 | ||
... | @@ -210,7 +206,6 @@ public class NettyMessagingService implements MessagingService { | ... | @@ -210,7 +206,6 @@ public class NettyMessagingService implements MessagingService { |
210 | ServerBootstrap b = new ServerBootstrap(); | 206 | ServerBootstrap b = new ServerBootstrap(); |
211 | b.option(ChannelOption.WRITE_BUFFER_HIGH_WATER_MARK, 32 * 1024); | 207 | b.option(ChannelOption.WRITE_BUFFER_HIGH_WATER_MARK, 32 * 1024); |
212 | b.option(ChannelOption.WRITE_BUFFER_LOW_WATER_MARK, 8 * 1024); | 208 | b.option(ChannelOption.WRITE_BUFFER_LOW_WATER_MARK, 8 * 1024); |
213 | - // TODO: Need JVM options to configure PooledByteBufAllocator. | ||
214 | b.option(ChannelOption.ALLOCATOR, PooledByteBufAllocator.DEFAULT); | 209 | b.option(ChannelOption.ALLOCATOR, PooledByteBufAllocator.DEFAULT); |
215 | b.group(serverGroup, clientGroup) | 210 | b.group(serverGroup, clientGroup) |
216 | .channel(serverChannelClass) | 211 | .channel(serverChannelClass) | ... | ... |
... | @@ -19,7 +19,7 @@ package org.onlab.thirdparty; | ... | @@ -19,7 +19,7 @@ package org.onlab.thirdparty; |
19 | /** | 19 | /** |
20 | * Empty class required to get the onlab-thirdparty module to build properly. | 20 | * Empty class required to get the onlab-thirdparty module to build properly. |
21 | * | 21 | * |
22 | - * TODO Figure out how to remove this. | 22 | + * NOTE Required for shade plugin to operate. |
23 | */ | 23 | */ |
24 | public class OnlabThirdparty { | 24 | public class OnlabThirdparty { |
25 | 25 | ... | ... |
... | @@ -54,7 +54,6 @@ import org.onosproject.net.intent.MultiPointToSinglePointIntent; | ... | @@ -54,7 +54,6 @@ import org.onosproject.net.intent.MultiPointToSinglePointIntent; |
54 | import org.onosproject.net.link.LinkEvent; | 54 | import org.onosproject.net.link.LinkEvent; |
55 | import org.onosproject.net.link.LinkListener; | 55 | import org.onosproject.net.link.LinkListener; |
56 | import org.onlab.osgi.ServiceDirectory; | 56 | import org.onlab.osgi.ServiceDirectory; |
57 | -import org.onlab.packet.Ethernet; | ||
58 | 57 | ||
59 | import java.io.IOException; | 58 | import java.io.IOException; |
60 | import java.util.ArrayList; | 59 | import java.util.ArrayList; |
... | @@ -369,7 +368,6 @@ public class TopologyViewWebSocket | ... | @@ -369,7 +368,6 @@ public class TopologyViewWebSocket |
369 | 368 | ||
370 | // FIXME: clearly, this is not enough | 369 | // FIXME: clearly, this is not enough |
371 | TrafficSelector selector = DefaultTrafficSelector.builder() | 370 | TrafficSelector selector = DefaultTrafficSelector.builder() |
372 | - .matchEthType(Ethernet.TYPE_IPV4) | ||
373 | .matchEthDst(dstHost.mac()).build(); | 371 | .matchEthDst(dstHost.mac()).build(); |
374 | TrafficTreatment treatment = DefaultTrafficTreatment.builder().build(); | 372 | TrafficTreatment treatment = DefaultTrafficTreatment.builder().build(); |
375 | 373 | ... | ... |
-
Please register or login to post a comment