Committed by
Gerrit Code Review
Added debug info to ArpHandler and priorities to RoutingPopulator
Change-Id: I079c5d50b12602ef620dbc6c5812d4508fa0b58d
Showing
2 changed files
with
4 additions
and
6 deletions
... | @@ -227,13 +227,11 @@ public class ArpHandler { | ... | @@ -227,13 +227,11 @@ public class ArpHandler { |
227 | .setSourceMACAddress(targetMac.toBytes()) | 227 | .setSourceMACAddress(targetMac.toBytes()) |
228 | .setEtherType(Ethernet.TYPE_ARP).setPayload(arpReply); | 228 | .setEtherType(Ethernet.TYPE_ARP).setPayload(arpReply); |
229 | 229 | ||
230 | - | 230 | + MacAddress hostMac = MacAddress.valueOf(arpReply.getTargetHardwareAddress()); |
231 | - HostId dstId = HostId.hostId( | 231 | + HostId dstId = HostId.hostId(hostMac, vlanId); |
232 | - MacAddress.valueOf(arpReply.getTargetHardwareAddress()), | ||
233 | - vlanId); | ||
234 | Host dst = srManager.hostService.getHost(dstId); | 232 | Host dst = srManager.hostService.getHost(dstId); |
235 | if (dst == null) { | 233 | if (dst == null) { |
236 | - log.warn("Cannot send ARP response to unknown device"); | 234 | + log.warn("Cannot send ARP response to host {}", dstId); |
237 | return; | 235 | return; |
238 | } | 236 | } |
239 | 237 | ... | ... |
... | @@ -260,7 +260,7 @@ public class RoutingRulePopulator { | ... | @@ -260,7 +260,7 @@ public class RoutingRulePopulator { |
260 | .makePermanent() | 260 | .makePermanent() |
261 | .nextStep(nextId) | 261 | .nextStep(nextId) |
262 | .withSelector(selector) | 262 | .withSelector(selector) |
263 | - .withPriority(100) | 263 | + .withPriority(2000 * ipPrefix.prefixLength()) |
264 | .withFlag(ForwardingObjective.Flag.SPECIFIC); | 264 | .withFlag(ForwardingObjective.Flag.SPECIFIC); |
265 | if (treatment != null) { | 265 | if (treatment != null) { |
266 | fwdBuilder.withTreatment(treatment); | 266 | fwdBuilder.withTreatment(treatment); | ... | ... |
-
Please register or login to post a comment