Merge "Fix of issue 377 for Notifications resolving."
authorEd Warnicke <eaw@cisco.com>
Thu, 30 Jan 2014 10:20:06 +0000 (10:20 +0000)
committerGerrit Code Review <gerrit@opendaylight.org>
Thu, 30 Jan 2014 10:20:07 +0000 (10:20 +0000)
opendaylight/web/troubleshoot/src/main/java/org/opendaylight/controller/troubleshoot/web/Troubleshoot.java
opendaylight/web/troubleshoot/src/main/resources/js/page.js

index e46b89ac2afe3fa2f46604f5a7f3fde2298181b3..6d79f3cb05cc7faf2469e3144fb6be44d9d21e81 100644 (file)
@@ -62,7 +62,7 @@ import org.springframework.web.bind.annotation.ResponseBody;
 public class Troubleshoot implements IDaylightWeb {
     private static final UserLevel AUTH_LEVEL = UserLevel.CONTAINERUSER;
     private static final List<String> flowStatsColumnNames = Arrays.asList("Node", "In Port",
-            "DL Src", "DL Dst", "DL Type", "DL Vlan", "NW Src", "NW Dst",
+            "DL Src", "DL Dst", "DL Type", "DL Vlan", "NW Src", "NW Dst","ToS Bits",
             "NW Proto", "TP Src", "TP Dst", "Actions", "Bytes", "Packets",
             "Time (s)", "Timeout (s)",
             "Priority");
@@ -229,6 +229,7 @@ public class Troubleshoot implements IDaylightWeb {
 
     private Map<String, String> convertPortsStatistics(
             NodeConnectorStatistics ncStats, String containerName) {
+
         Map<String, String> row = new HashMap<String, String>();
 
         ISwitchManager switchManager = (ISwitchManager) ServiceHelper
@@ -325,6 +326,12 @@ public class Troubleshoot implements IDaylightWeb {
         } else {
             row.put(MatchType.NW_DST.id(), "*");
         }
+        if (match.isPresent(MatchType.NW_TOS)) {
+            row.put(MatchType.NW_TOS.id(), ((Byte) flow.getMatch()
+                        .getField(MatchType.NW_TOS).getValue()).toString());
+        } else {
+            row.put(MatchType.NW_TOS.id(), "*");
+        }
         if (match.isPresent(MatchType.NW_PROTO)) {
             row.put(MatchType.NW_PROTO.id(),
                     IPProtocols.getProtocolName(((Byte) flow.getMatch()
index a8673b0031d7246bedcfb3285a90519694b48efb..4b5e51a0718377e449c799dd807cc2cf798992ec 100644 (file)
@@ -373,6 +373,11 @@ one.f.troubleshooting.existingNodes = {
                             label: 'NW Dst',
                             sortable: true
                         },
+                        {
+                            property: 'nwTOS',
+                            label: 'ToS Bits',
+                            sortable: true
+                        },
                         {
                             property: 'nwProto',
                             label: 'NW Proto',
@@ -437,6 +442,7 @@ one.f.troubleshooting.existingNodes = {
                     entry.push(value["dlVlan"]);
                     entry.push(value["nwSrc"]);
                     entry.push(value["nwDst"]);
+                    entry.push(value["nwTOS"]);
                     entry.push(value["nwProto"]);
                     entry.push(value["tpSrc"]);
                     entry.push(value["tpDst"]);