. * * @package LibreNMS * @link http://librenms.org * @copyright 2021 Tony Murray * @author Tony Murray */ namespace LibreNMS; use LibreNMS\Interfaces\Data\DataStorageInterface; use LibreNMS\Interfaces\Polling\OSPolling; use LibreNMS\RRD\RrdDefinition; class Waas extends OS implements OSPolling { public function pollOS(DataStorageInterface $datastore): void { $connections = \SnmpQuery::get('CISCO-WAN-OPTIMIZATION-MIB::cwoTfoStatsActiveOptConn.0')->value(); if (is_numeric($connections)) { $datastore->put($this->getDeviceArray(), 'waas_cwotfostatsactiveoptconn', [ 'rrd_def' => RrdDefinition::make()->addDataset('connections', 'GAUGE', 0), ], [ 'connections' => $connections, ]); $this->enableGraph('waas_cwotfostatsactiveoptconn'); } } }