- spLogger.info("Send request for stats collection to node : {})",targetNode.getId());
-
- InstanceIdentifier<Node> targetInstanceId = InstanceIdentifier.builder(Nodes.class).child(Node.class,targetNode.getKey()).toInstance();
-
- NodeRef targetNodeRef = new NodeRef(targetInstanceId);
-
- try{
- sendAggregateFlowsStatsFromAllTablesRequest(targetNode.getKey());
-
- sendAllFlowsStatsFromAllTablesRequest(targetNodeRef);
-
- sendAllNodeConnectorsStatisticsRequest(targetNodeRef);
-
- sendAllFlowTablesStatisticsRequest(targetNodeRef);
-
- sendAllQueueStatsFromAllNodeConnector (targetNodeRef);
-
- sendAllGroupStatisticsRequest(targetNodeRef);
-
- sendAllMeterStatisticsRequest(targetNodeRef);
-
- sendGroupDescriptionRequest(targetNodeRef);
-
- sendMeterConfigStatisticsRequest(targetNodeRef);
- }catch(Exception e){
- spLogger.error("Exception occured while sending statistics requests : {}", e);
- }
+ public void sendStatisticsRequestsToNode(Node targetNode){
+
+ spLogger.debug("Send requests for statistics collection to node : {})",targetNode.getId());
+
+ InstanceIdentifier<Node> targetInstanceId = InstanceIdentifier.builder(Nodes.class).child(Node.class,targetNode.getKey()).toInstance();
+
+ NodeRef targetNodeRef = new NodeRef(targetInstanceId);
+
+ try{
+ if(flowStatsService != null){
+ sendAggregateFlowsStatsFromAllTablesRequest(targetNode.getKey());
+ sendAllFlowsStatsFromAllTablesRequest(targetNodeRef);
+ }
+ if(flowTableStatsService != null){
+ sendAllFlowTablesStatisticsRequest(targetNodeRef);
+ }
+ if(portStatsService != null){
+ sendAllNodeConnectorsStatisticsRequest(targetNodeRef);
+ }
+ if(groupStatsService != null){
+ sendAllGroupStatisticsRequest(targetNodeRef);
+ sendGroupDescriptionRequest(targetNodeRef);
+ }
+ if(meterStatsService != null){
+ sendAllMeterStatisticsRequest(targetNodeRef);
+ sendMeterConfigStatisticsRequest(targetNodeRef);
+ }
+ if(queueStatsService != null){
+ sendAllQueueStatsFromAllNodeConnector (targetNodeRef);