Bug fix: flow statistics are not notified if empty
[controller.git] / opendaylight / protocol_plugins / openflow / src / main / java / org / opendaylight / controller / protocol_plugin / openflow / internal / ReadServiceFilter.java
index b8f6ab4..7f9a13e 100644 (file)
@@ -587,9 +587,7 @@ public class ReadServiceFilter implements IReadServiceFilter, IContainerListener
             flowOnNodeList = filterFlowListPerContainer(container, node, flowOnNodeList);
 
             // notify listeners
-            if (!flowOnNodeList.isEmpty()) {
-                l.getValue().nodeFlowStatisticsUpdated(node, flowOnNodeList);
-            }
+            l.getValue().nodeFlowStatisticsUpdated(node, flowOnNodeList);
         }
     }
 
@@ -606,9 +604,8 @@ public class ReadServiceFilter implements IReadServiceFilter, IContainerListener
                     .getNodeConnectorStatsList();
 
             // notify listeners
-            if (!ncStatsList.isEmpty()) {
-                l.getValue().nodeConnectorStatisticsUpdated(node, ncStatsList);
-            }
+            l.getValue().nodeConnectorStatisticsUpdated(node, ncStatsList);
+
         }
     }
 
@@ -625,9 +622,7 @@ public class ReadServiceFilter implements IReadServiceFilter, IContainerListener
                     .getNodeTableStatsList();
 
             // notify listeners
-            if (!tableStatsList.isEmpty()) {
-                l.getValue().nodeTableStatisticsUpdated(node, tableStatsList);
-            }
+            l.getValue().nodeTableStatisticsUpdated(node, tableStatsList);
         }
     }
 }