LCOV - code coverage report
Current view: top level - vnsw/agent/uve - vrouter_stats_collector.cc (source / functions) Hit Total Coverage
Test: OpenSDN C/C++ coverage (all TARGET_SET jobs) Lines: 9 14 64.3 %
Date: 2026-11-09 02:10:49 Functions: 4 5 80.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /*
       2             :  * Copyright (c) 2013 Juniper Networks, Inc. All rights reserved.
       3             :  * Copyright Contributors to the OpenSDN project
       4             :  */
       5             : 
       6             : #include <db/db.h>
       7             : #include <cmn/agent_cmn.h>
       8             : #include <init/agent_param.h>
       9             : #include <uve/stats_collector.h>
      10             : #include <uve/vrouter_stats_collector.h>
      11             : 
      12           2 : VrouterStatsCollector::VrouterStatsCollector(boost::asio::io_service &io,
      13           2 :                                              AgentUveBase *uve) :
      14             :     StatsCollector(TaskScheduler::GetInstance()->GetTaskId("Agent::Uve"),
      15             :                    0, io, uve->agent()->params()->vrouter_stats_interval(),
      16             :                    "Vrouter stats collector"),
      17           2 :     agent_uve_(uve) {
      18           2 : }
      19             : 
      20           4 : VrouterStatsCollector::~VrouterStatsCollector() {
      21           4 : }
      22             : 
      23           0 : bool VrouterStatsCollector::Run() {
      24           0 :     run_counter_++;
      25           0 :     agent_uve_->vrouter_uve_entry()->SendVrouterMsg();
      26             :     /* We have not registered for ACL notification. So total_acl_rules
      27             :      * of VN is periodically polled from VN ACL and VN UVE is sent if there
      28             :      * are any changes.
      29             :      */
      30           0 :     agent_uve_->vn_uve_table()->SendVnAclRuleCount();
      31           0 :     return true;
      32             : }
      33             : 
      34           2 : void VrouterStatsCollector::Shutdown() {
      35           2 :     StatsCollector::Shutdown();
      36           2 : }

Generated by: LCOV version 1.14