X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Farphandler%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Farphandler%2Finternal%2FArpHandler.java;h=083e2ed0e9784d31355ceaac1a995bde2c386278;hb=e467b27c2487308a0e4b12f3565b6e1077e103e2;hp=fa883829cccf6c9f69044f3346e364ea4c2f9c5d;hpb=d9de6c2ddfb30eb2eee782c229f6e03cef352bbd;p=controller.git diff --git a/opendaylight/arphandler/src/main/java/org/opendaylight/controller/arphandler/internal/ArpHandler.java b/opendaylight/arphandler/src/main/java/org/opendaylight/controller/arphandler/internal/ArpHandler.java index fa883829cc..083e2ed0e9 100644 --- a/opendaylight/arphandler/src/main/java/org/opendaylight/controller/arphandler/internal/ArpHandler.java +++ b/opendaylight/arphandler/src/main/java/org/opendaylight/controller/arphandler/internal/ArpHandler.java @@ -113,16 +113,6 @@ public class ArpHandler implements IHostFinder, IListenDataPacket, ICacheUpdateA } } - void setRouting(IRouting r) { - this.routing = r; - } - - void unsetRouting(IRouting r) { - if (this.routing == r) { - this.routing = null; - } - } - void setHostListener(IfHostListener s) { if (this.hostListeners != null) { this.hostListeners.add(s); @@ -507,41 +497,18 @@ public class ArpHandler implements IHostFinder, IListenDataPacket, ICacheUpdateA // see if we know about the host // Hosttracker hosts db key implementation - IHostId id = HostIdFactory.create(dIP, null); - HostNodeConnector host = hostTracker.hostFind(id); + HostNodeConnector host = hostTracker.hostFind(dIP); if (host == null) { - // if we don't, know about the host, try to find it + // if we don't know about the host, try to find it log.trace("Punted IP pkt to {}, sending bcast ARP event...", dIP); /* * unknown destination host, initiate bcast ARP request */ arpRequestReplyEvent.put(new ARPRequest(dIP, subnet), false); - } else if (routing == null || routing.getRoute(p.getNode(), host.getnodeconnectorNode()) != null) { - /* - * if IRouting is available, make sure that this packet can get it's - * destination normally before teleporting it there. If it's not - * available, then assume it's reachable. - * - * TODO: come up with a way to do this in the absence of IRouting - */ - - log.trace("forwarding punted IP pkt to {} received at {}", dIP, p); - - /* - * if we know where the host is and there's a path from where this - * packet was punted to where the host is, then deliver it to the - * host for now - */ - NodeConnector nc = host.getnodeConnector(); - - // re-encode the Ethernet packet (the parent of the IPv4 packet) - RawPacket rp = this.dataPacketService.encodeDataPacket(pkt.getParent()); - rp.setOutgoingNodeConnector(nc); - this.dataPacketService.transmitDataPacket(rp); } else { - log.trace("ignoring punted IP pkt to {} because there is no route from {}", dIP, p); + log.trace("Ignoring punted IP pkt to known host: {} (received on: {})", dIP, p); } }