From e52e67767076b29cb01939aa7bdd8fee9d205cc1 Mon Sep 17 00:00:00 2001 From: Ashlee Young Date: Fri, 23 Oct 2015 08:31:31 -0700 Subject: Update ONOS src to commit id 69b36d5d11e81e28e56b46ba44e4b8cd701c5867 Change-Id: I9c13045711dbf9c0181106b66a6bf22c72bcf330 Signed-off-by: Ashlee Young --- .../segmentrouting/DefaultRoutingHandler.java | 18 ++++++++++-------- .../segmentrouting/DeviceConfiguration.java | 12 ++++++------ .../segmentrouting/ECMPShortestPathGraph.java | 8 ++++---- .../java/org/onosproject/segmentrouting/IpHandler.java | 2 +- .../segmentrouting/RoutingRulePopulator.java | 8 ++++---- .../segmentrouting/SegmentRoutingManager.java | 3 ++- .../grouphandler/DefaultEdgeGroupHandler.java | 9 +++++---- 7 files changed, 32 insertions(+), 28 deletions(-) (limited to 'framework/src/onos/apps/segmentrouting') diff --git a/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/DefaultRoutingHandler.java b/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/DefaultRoutingHandler.java index 8b447af4..40ee55fc 100644 --- a/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/DefaultRoutingHandler.java +++ b/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/DefaultRoutingHandler.java @@ -93,7 +93,7 @@ public class DefaultRoutingHandler { try { populationStatus = Status.STARTED; rulePopulator.resetCounter(); - log.info("Starts to populate routing rules"); + log.info("Starting to populate segment-routing rules"); log.debug("populateAllRoutingRules: populationStatus is STARTED"); for (Device sw : srManager.deviceService.getDevices()) { @@ -117,7 +117,7 @@ public class DefaultRoutingHandler { log.debug("populateAllRoutingRules: populationStatus is SUCCEEDED"); populationStatus = Status.SUCCEEDED; - log.info("Completes routing rule population. Total # of rules pushed : {}", + log.info("Completed routing rule population. Total # of rules pushed : {}", rulePopulator.getCounter()); return true; } finally { @@ -426,7 +426,7 @@ public class DefaultRoutingHandler { .get(itrIdx); for (DeviceId targetSw : swViaMap.keySet()) { Set nextHops = new HashSet<>(); - + log.debug("** Iter: {} root: {} target: {}", itrIdx, destSw, targetSw); for (ArrayList via : swViaMap.get(targetSw)) { if (via.isEmpty()) { nextHops.add(destSw); @@ -456,7 +456,7 @@ public class DefaultRoutingHandler { // rule for both subnet and router IP. if (config.isEdgeDevice(targetSw) && config.isEdgeDevice(destSw)) { List subnets = config.getSubnets(destSw); - log.debug("populateEcmpRoutingRulePartial in device {} towards {} for subnets {}", + log.debug("* populateEcmpRoutingRulePartial in device {} towards {} for subnets {}", targetSw, destSw, subnets); result = rulePopulator.populateIpRuleForSubnet(targetSw, subnets, @@ -468,7 +468,7 @@ public class DefaultRoutingHandler { Ip4Address routerIp = config.getRouterIp(destSw); IpPrefix routerIpPrefix = IpPrefix.valueOf(routerIp, IpPrefix.MAX_INET_MASK_LENGTH); - log.debug("populateEcmpRoutingRulePartial in device {} towards {} for router IP {}", + log.debug("* populateEcmpRoutingRulePartial in device {} towards {} for router IP {}", targetSw, destSw, routerIpPrefix); result = rulePopulator.populateIpRuleForRouter(targetSw, routerIpPrefix, destSw, nextHops); if (!result) { @@ -479,7 +479,7 @@ public class DefaultRoutingHandler { } else if (config.isEdgeDevice(targetSw)) { Ip4Address routerIp = config.getRouterIp(destSw); IpPrefix routerIpPrefix = IpPrefix.valueOf(routerIp, IpPrefix.MAX_INET_MASK_LENGTH); - log.debug("populateEcmpRoutingRulePartial in device {} towards {} for router IP {}", + log.debug("* populateEcmpRoutingRulePartial in device {} towards {} for router IP {}", targetSw, destSw, routerIpPrefix); result = rulePopulator.populateIpRuleForRouter(targetSw, routerIpPrefix, destSw, nextHops); if (!result) { @@ -488,7 +488,7 @@ public class DefaultRoutingHandler { } // Populates MPLS rules to all routers - log.debug("populateEcmpRoutingRulePartial in device{} towards {} for all MPLS rules", + log.debug("* populateEcmpRoutingRulePartial in device{} towards {} for all MPLS rules", targetSw, destSw); result = rulePopulator.populateMplsRule(targetSw, destSw, nextHops); if (!result) { @@ -500,7 +500,7 @@ public class DefaultRoutingHandler { /** * Populates table miss entries for all tables, and pipeline rules for VLAN - * and TACM tables. + * and TCAM tables. XXX rename/rethink * * @param deviceId Switch ID to set the rules */ @@ -534,6 +534,8 @@ public class DefaultRoutingHandler { /** * Resume the flow rule population process if it was aborted for any reason. * Mostly the process is aborted when the groups required are not set yet. + * XXX is this called? + * */ public void resumePopulationProcess() { statusLock.lock(); diff --git a/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/DeviceConfiguration.java b/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/DeviceConfiguration.java index eef1b147..0bc155b8 100644 --- a/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/DeviceConfiguration.java +++ b/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/DeviceConfiguration.java @@ -134,7 +134,7 @@ public class DeviceConfiguration implements DeviceProperties { @Override public int getSegmentId(DeviceId deviceId) { if (deviceConfigMap.get(deviceId) != null) { - log.debug("getSegmentId for device{} is {}", + log.trace("getSegmentId for device{} is {}", deviceId, deviceConfigMap.get(deviceId).nodeSid); return deviceConfigMap.get(deviceId).nodeSid; @@ -189,7 +189,7 @@ public class DeviceConfiguration implements DeviceProperties { @Override public MacAddress getDeviceMac(DeviceId deviceId) { if (deviceConfigMap.get(deviceId) != null) { - log.debug("getDeviceMac for device{} is {}", + log.trace("getDeviceMac for device{} is {}", deviceId, deviceConfigMap.get(deviceId).mac); return deviceConfigMap.get(deviceId).mac; @@ -209,7 +209,7 @@ public class DeviceConfiguration implements DeviceProperties { */ public Ip4Address getRouterIp(DeviceId deviceId) { if (deviceConfigMap.get(deviceId) != null) { - log.debug("getDeviceIp for device{} is {}", + log.trace("getDeviceIp for device{} is {}", deviceId, deviceConfigMap.get(deviceId).ip); return deviceConfigMap.get(deviceId).ip; @@ -231,7 +231,7 @@ public class DeviceConfiguration implements DeviceProperties { @Override public boolean isEdgeDevice(DeviceId deviceId) { if (deviceConfigMap.get(deviceId) != null) { - log.debug("isEdgeDevice for device{} is {}", + log.trace("isEdgeDevice for device{} is {}", deviceId, deviceConfigMap.get(deviceId).isEdge); return deviceConfigMap.get(deviceId).isEdge; @@ -297,7 +297,7 @@ public class DeviceConfiguration implements DeviceProperties { */ public List getSubnetGatewayIps(DeviceId deviceId) { if (deviceConfigMap.get(deviceId) != null) { - log.debug("getSubnetGatewayIps for device{} is {}", + log.trace("getSubnetGatewayIps for device{} is {}", deviceId, deviceConfigMap.get(deviceId).gatewayIps.values()); return new ArrayList<>(deviceConfigMap.get(deviceId).gatewayIps.values()); @@ -314,7 +314,7 @@ public class DeviceConfiguration implements DeviceProperties { */ public List getSubnets(DeviceId deviceId) { if (deviceConfigMap.get(deviceId) != null) { - log.debug("getSubnets for device{} is {}", + log.trace("getSubnets for device{} is {}", deviceId, deviceConfigMap.get(deviceId).subnets.values()); return new ArrayList<>(deviceConfigMap.get(deviceId).subnets.values()); diff --git a/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/ECMPShortestPathGraph.java b/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/ECMPShortestPathGraph.java index 2e2041c4..e9a59bae 100644 --- a/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/ECMPShortestPathGraph.java +++ b/framework/src/onos/apps/segmentrouting/src/main/java/org/onosproject/segmentrouting/ECMPShortestPathGraph.java @@ -31,7 +31,7 @@ import java.util.List; /** * This class creates bandwidth constrained breadth first tree and returns paths - * from root Device to leaf Devicees which satisfies the bandwidth condition. If + * from root Device to leaf Devices which satisfies the bandwidth condition. If * bandwidth parameter is not specified, the normal breadth first tree will be * calculated. The paths are snapshot paths at the point of the class * instantiation. @@ -281,7 +281,7 @@ public class ECMPShortestPathGraph { * Return the complete info of the computed ECMP paths for each Device * learned in multiple iterations from the root Device. * - * @return the hash table of Devicees learned in multiple Dijkstra + * @return the hash table of Devices learned in multiple Dijkstra * iterations and corresponding ECMP paths to it from the root * Device */ @@ -305,8 +305,8 @@ public class ECMPShortestPathGraph { * Return the complete info of the computed ECMP paths for each Device * learned in multiple iterations from the root Device. * - * @return the hash table of Devicees learned in multiple Dijkstra - * iterations and corresponding ECMP paths in terms of Devicees to + * @return the hash table of Devices learned in multiple Dijkstra + * iterations and corresponding ECMP paths in terms of Devices to * be traversed to it from the root Device */ public HashMap