Exemplo n.º 1
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge("datadog.agent.collector.collection.time")
     self.gauge("datadog.agent.emitter.emit.time")
     self.gauge("datadog.agent.collector.threads.count")
     self.gauge("datadog.agent.collector.cpu.used")
Exemplo n.º 2
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.cpu.user')
     self.gauge('system.cpu.idle')
     self.gauge('system.cpu.interrupt')
     self.gauge('system.cpu.system')
Exemplo n.º 3
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.counter("system.cpu.user")
        self.counter("system.cpu.idle")
        self.counter("system.cpu.system")
        self.counter("system.cpu.interrupt")
Exemplo n.º 4
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        # Sampler(s)
        self.os_wmi_sampler = WMISampler(
            logger,
            "Win32_OperatingSystem",
            ["TotalVisibleMemorySize", "FreePhysicalMemory"]
        )
        self.mem_wmi_sampler = WMISampler(
            logger,
            "Win32_PerfRawData_PerfOS_Memory",
            ["CacheBytes", "CommittedBytes", "PoolPagedBytes", "PoolNonpagedBytes"])

        self.gauge('system.mem.free')
        self.gauge('system.mem.used')
        self.gauge('system.mem.total')
        # area of physical memory that stores recently used pages of data
        # for applications
        self.gauge('system.mem.cached')
        # Committed memory is physical memory for which space has been
        # reserved on the disk paging file in case it must be written
        # back to disk
        self.gauge('system.mem.committed')
        # physical memory used by the operating system, for objects
        # that can be written to disk when they are not being used
        self.gauge('system.mem.paged')
        # physical memory used by the operating system for objects that
        # cannot be written to disk, but must remain in physical memory
        # as long as they are allocated.
        self.gauge('system.mem.nonpaged')
        # usable = free + cached
        self.gauge('system.mem.usable')
        self.gauge('system.mem.pct_usable')
Exemplo n.º 5
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.networkTrafficStore = {}
        self.networkTrafficStore["last_ts"] = time.time()
        self.networkTrafficStore["current_ts"] = self.networkTrafficStore[
            "last_ts"]
Exemplo n.º 6
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.disk.free')
     self.gauge('system.disk.total')
     self.gauge('system.disk.in_use')
     self.gauge('system.disk.used')
Exemplo n.º 7
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.counter('system.cpu.user')
        self.counter('system.cpu.idle')
        self.counter('system.cpu.system')
        self.counter('system.cpu.interrupt')
Exemplo n.º 8
0
    def __init__(self):
        super(Http, self).__init__()
        self.check = Check()

        configuration = Config()
        self.average_threshold = int(
            configuration.parse_config("Ressie", "http_average_coefficient"))
Exemplo n.º 9
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('datadog.agent.collector.collection.time')
     self.gauge('datadog.agent.emitter.emit.time')
     self.gauge('datadog.agent.collector.threads.count')
     self.gauge('datadog.agent.collector.cpu.used')
Exemplo n.º 10
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.gauge('system.proc.queue_length')
        self.gauge('system.proc.count')
        self.numprocs = WinPDHCounter('System', 'Processes', logger)
        self.pql = WinPDHCounter('System', 'Processor Queue Length', logger)
Exemplo n.º 11
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.disk.free')
     self.gauge('system.disk.total')
     self.gauge('system.disk.in_use')
     self.gauge('system.disk.used')
Exemplo n.º 12
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.gauge('system.mem.free')
        self.gauge('system.mem.used')
        self.gauge('system.mem.total')
        # area of physical memory that stores recently used pages of data
        # for applications
        self.gauge('system.mem.cached')
        # Committed memory is physical memory for which space has been
        # reserved on the disk paging file in case it must be written
        # back to disk
        self.gauge('system.mem.committed')
        # physical memory used by the operating system, for objects
        # that can be written to disk when they are not being used
        self.gauge('system.mem.paged')
        # physical memory used by the operating system for objects that
        # cannot be written to disk, but must remain in physical memory
        # as long as they are allocated.
        self.gauge('system.mem.nonpaged')
        # usable = free + cached
        self.gauge('system.mem.usable')
        self.gauge('system.mem.pct_usable')
        #  details about the usage of the pagefile.
        self.gauge('system.mem.pagefile.total')
        self.gauge('system.mem.pagefile.used')
        self.gauge('system.mem.pagefile.free')
        self.gauge('system.mem.pagefile.pct_free')

        self.cache_bytes_counter = WinPDHCounter('Memory', 'Cache Bytes', logger)
        self.committed_bytes_counter = WinPDHCounter('Memory', 'Committed Bytes', logger)
        self.pool_paged_bytes_counter = WinPDHCounter('Memory', 'Pool Paged Bytes', logger)
        self.pool_non_paged_bytes_counter = WinPDHCounter('Memory', 'Pool Nonpaged Bytes', logger)
Exemplo n.º 13
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.os_wmi_sampler = WMISampler(
            logger, "Win32_OperatingSystem",
            ["TotalVisibleMemorySize", "FreePhysicalMemory"])
        self.mem_wmi_sampler = WMISampler(
            logger, "Win32_PerfRawData_PerfOS_Memory", [
                "CacheBytes", "CommittedBytes", "PoolPagedBytes",
                "PoolNonpagedBytes"
            ])

        self.gauge('system.mem.free')
        self.gauge('system.mem.used')
        self.gauge('system.mem.total')

        self.gauge('system.mem.cached')

        self.gauge('system.mem.committed')

        self.gauge('system.mem.paged')

        self.gauge('system.mem.nonpaged')
        self.gauge('system.mem.usable')
        self.gauge('system.mem.pct_usage')
Exemplo n.º 14
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        # Sampler(s)
        self.os_wmi_sampler = WMISampler(
            logger, "Win32_OperatingSystem",
            ["TotalVisibleMemorySize", "FreePhysicalMemory"])
        self.mem_wmi_sampler = WMISampler(
            logger, "Win32_PerfRawData_PerfOS_Memory", [
                "CacheBytes", "CommittedBytes", "PoolPagedBytes",
                "PoolNonpagedBytes"
            ])

        self.gauge('system.mem.free')
        self.gauge('system.mem.used')
        self.gauge('system.mem.total')
        # area of physical memory that stores recently used pages of data
        # for applications
        self.gauge('system.mem.cached')
        # Committed memory is physical memory for which space has been
        # reserved on the disk paging file in case it must be written
        # back to disk
        self.gauge('system.mem.committed')
        # physical memory used by the operating system, for objects
        # that can be written to disk when they are not being used
        self.gauge('system.mem.paged')
        # physical memory used by the operating system for objects that
        # cannot be written to disk, but must remain in physical memory
        # as long as they are allocated.
        self.gauge('system.mem.nonpaged')
        # usable = free + cached
        self.gauge('system.mem.usable')
        self.gauge('system.mem.pct_usable')
Exemplo n.º 15
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.counter('system.cpu.user')
     self.counter('system.cpu.idle')
     self.gauge('system.cpu.interrupt')
     self.counter('system.cpu.system')
Exemplo n.º 16
0
    def __init__(self, logger):
        Check.__init__(self, logger)
        self.mysqlVersion = None
        self.db = None
        self.logger = logger
        self.slowProcessThreshold = 5
        self.replicationUser = '******'

        # Register metrics
        self.counter("mysqlConnections")
        self.gauge("mysqlCreatedTmpDiskTables")
        self.gauge("mysqlMaxUsedConnections")
        self.gauge("mysqlOpenFiles")
        self.counter("mysqlSlowQueries")
        self.counter("mysqlQuestions")
        self.counter("mysqlQueries")
        self.gauge("mysqlSlowProcessCount")
        self.gauge("mysqlSlowProcessMax")
        self.gauge("mysqlTableLocksWaited")
        self.gauge("mysqlThreadsConnected")
        self.gauge("mysqlSecondsBehindMaster")

        self.counter("mysqlInnodbDataReads")
        self.counter("mysqlInnodbDataWrites")
        self.counter("mysqlInnodbOsLogFsyncs")

        self.counter("mysqlUserTime")
        self.counter("mysqlKernelTime")
Exemplo n.º 17
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.io.wkb_s')
     self.gauge('system.io.w_s')
     self.gauge('system.io.rkb_s')
     self.gauge('system.io.r_s')
     self.gauge('system.io.avg_q_sz')
Exemplo n.º 18
0
    def __init__(self, logger):
        Check.__init__(self, logger)
        self.solaris_re = re.compile("([ro]bytes64)|errors|collisions")

        # FIXME rework linux support to use the built-in Check logic
        self.networkTrafficStore = {}
        self.networkTrafficStore["last_ts"] = time.time()
        self.networkTrafficStore["current_ts"] = self.networkTrafficStore["last_ts"]
Exemplo n.º 19
0
 def __init__(self, logger):
     """Declare a single gauge that will record the second value of its invocation"""
     # Super-initialization
     Check.__init__(self, logger)
     self.logger.info("Initializing custom check %s" % self.__class__)
     # Declare which metric(s) you want to save
     self.gauge("dd.custom.agent.second")
     self.counter("dd.custom.agent.check_rate")
Exemplo n.º 20
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        # Sampler(s)
        self.wmi_sampler = WMISampler(logger, "Win32_PerfRawData_PerfOS_System", ["ProcessorQueueLength", "Processes"])

        self.gauge("system.proc.queue_length")
        self.gauge("system.proc.count")
Exemplo n.º 21
0
 def __init__(self, logger):
     """Declare a single gauge that will record the second value of its invocation"""
     # Super-initialization
     Check.__init__(self, logger)
     self.logger.info("Initializing custom check %s" % self.__class__)
     # Declare which metric(s) you want to save
     self.gauge("dd.custom.agent.second")
     self.counter("dd.custom.agent.check_rate")
Exemplo n.º 22
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.io.wkb_s')
     self.gauge('system.io.w_s')
     self.gauge('system.io.rkb_s')
     self.gauge('system.io.r_s')
     self.gauge('system.io.avg_q_sz')
Exemplo n.º 23
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.disk.free')
     self.gauge('system.disk.total')
     self.gauge('system.disk.in_use')
     self.gauge('system.disk.used')
     self.counter("system.disk.read_time_pct")
     self.counter("system.disk.write_time_pct")
Exemplo n.º 24
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.wmi_sampler = WMISampler(
            logger, "Win32_PerfRawData_Tcpip_NetworkInterface",
            ["Name", "BytesReceivedPerSec", "BytesSentPerSec"])

        self.gauge('system.net.bytes_rcvd')
        self.gauge('system.net.bytes_sent')
Exemplo n.º 25
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.disk.free')
     self.gauge('system.disk.total')
     self.gauge('system.disk.in_use')
     self.gauge('system.disk.used')
     self.counter("system.disk.read_time_pct")
     self.counter("system.disk.write_time_pct")
Exemplo n.º 26
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.wmi_sampler = WMISampler(logger,
                                      "Win32_PerfRawData_PerfOS_System",
                                      ["ProcessorQueueLength", "Processes"])

        self.gauge('system.proc.queue_length')
        self.gauge('system.proc.count')
Exemplo n.º 27
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.counter('system.cpu.user')
        self.counter('system.cpu.idle')
        self.counter('system.cpu.system')
        self.counter('system.cpu.interrupt')

        self.cpu_interrupt_counter = WinPDHCounter('Processor', '% Interrupt Time', logger, instance_name="_Total")
Exemplo n.º 28
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        # Sampler(s)
        self.wmi_sampler = WMISampler(
            logger, "Win32_PerfRawData_Tcpip_NetworkInterface", ["Name", "BytesReceivedPerSec", "BytesSentPerSec"]
        )

        self.gauge("system.net.bytes_rcvd")
        self.gauge("system.net.bytes_sent")
Exemplo n.º 29
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        def generate_metric(name, xtype, *args):
            if xtype == "counter":
                self.counter(name)
            else:
                self.gauge(name)

        self._map_metric(generate_metric)
Exemplo n.º 30
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        # Sampler(s)
        self.wmi_sampler = WMISampler(logger, "Win32_PerfRawData_PerfOS_Processor", ["Name", "PercentInterruptTime"])

        self.counter("system.cpu.user")
        self.counter("system.cpu.idle")
        self.gauge("system.cpu.interrupt")
        self.counter("system.cpu.system")
Exemplo n.º 31
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.mem.free')
     self.gauge('system.mem.used')
     self.gauge('system.mem.total')
     self.gauge('system.mem.cached')
     self.gauge('system.mem.committed')
     self.gauge('system.mem.paged')
     self.gauge('system.mem.nonpaged')
Exemplo n.º 32
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.mem.free')
     self.gauge('system.mem.used')
     self.gauge('system.mem.total')
     self.gauge('system.mem.cached')
     self.gauge('system.mem.committed')
     self.gauge('system.mem.paged')
     self.gauge('system.mem.nonpaged')
Exemplo n.º 33
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     macV = None
     if sys.platform == 'darwin':
         macV = platform.mac_ver()
         macV_minor_version = int(re.match(r'10\.(\d+)\.?.*', macV[0]).group(1))
     
     # Output from top is slightly modified on OS X 10.6 (case #28239) and greater
     if macV and (macV_minor_version >= 6):
         self.topIndex = 6
     else:
         self.topIndex = 5
Exemplo n.º 34
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        # Sampler(s)
        self.wmi_sampler = WMISampler(logger,
                                      "Win32_PerfRawData_PerfOS_Processor",
                                      ["Name", "PercentInterruptTime"])

        self.counter('system.cpu.user')
        self.counter('system.cpu.idle')
        self.gauge('system.cpu.interrupt')
        self.counter('system.cpu.system')
Exemplo n.º 35
0
    def __init__(self, logger):
        Check.__init__(self, logger)
        macV = None
        if sys.platform == 'darwin':
            macV = platform.mac_ver()
            macV_minor_version = int(
                re.match(r'10\.(\d+)\.?.*', macV[0]).group(1))

        # Output from top is slightly modified on OS X 10.6 (case #28239) and greater
        if macV and (macV_minor_version >= 6):
            self.topIndex = 6
        else:
            self.topIndex = 5
Exemplo n.º 36
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.gauge('system.io.wkb_s')
        self.gauge('system.io.w_s')
        self.gauge('system.io.rkb_s')
        self.gauge('system.io.r_s')
        self.gauge('system.io.avg_q_sz')

        self.dwbpscounter = WinPDHCounter('LogicalDisk', 'Disk Write Bytes/sec', logger)
        self.dwpscounter = WinPDHCounter('LogicalDisk', 'Disk Writes/sec', logger)
        self.drbpscounter = WinPDHCounter('LogicalDisk', 'Disk Read Bytes/sec', logger)
        self.drpscounter = WinPDHCounter('LogicalDisk', 'Disk Reads/sec', logger)
        self.qszcounter = WinPDHCounter('LogicalDisk', 'Current Disk Queue Length', logger)
Exemplo n.º 37
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.wmi_sampler = WMISampler(
            logger, "Win32_PerfRawData_PerfDisk_LogicalDisk", [
                "Name", "DiskWriteBytesPerSec", "DiskWritesPerSec",
                "DiskReadBytesPerSec", "DiskReadsPerSec",
                "CurrentDiskQueueLength"
            ])

        self.gauge('system.io.wkb_s')
        self.gauge('system.io.w_s')
        self.gauge('system.io.rkb_s')
        self.gauge('system.io.r_s')
        self.gauge('system.io.avg_q_sz')
Exemplo n.º 38
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        #  Sampler(s)
        self.wmi_sampler = WMISampler(
            logger,
            "Win32_PerfRawData_PerfDisk_LogicalDisk",
            ["Name", "DiskWriteBytesPerSec", "DiskWritesPerSec", "DiskReadBytesPerSec",
             "DiskReadsPerSec", "CurrentDiskQueueLength"]
        )

        self.gauge('system.io.wkb_s')
        self.gauge('system.io.w_s')
        self.gauge('system.io.rkb_s')
        self.gauge('system.io.r_s')
        self.gauge('system.io.avg_q_sz')
Exemplo n.º 39
0
    def __init__(self, logger):
        Check.__init__(self, logger)
        macV = None
        if sys.platform == 'darwin':
            macV = platform.mac_ver()
            macV_minor_version = int(re.match(r'10\.(\d+)\.?.*', macV[0]).group(1))

        if macV and (macV_minor_version >= 6):
            self.topIndex = 6
        else:
            self.topIndex = 5

        self.pagesize = 0
        if sys.platform == 'sunos5':
            try:
                pgsz, _, _ = get_subprocess_output(['pagesize'], self.logger)
                self.pagesize = int(pgsz.strip())
            except Exception:
                pass
Exemplo n.º 40
0
    def __init__(self, logger):
        Check.__init__(self, logger)
        macV = None
        if sys.platform == "darwin":
            macV = platform.mac_ver()
            macV_minor_version = int(re.match(r"10\.(\d+)\.?.*", macV[0]).group(1))

        # Output from top is slightly modified on OS X 10.6 (case #28239) and greater
        if macV and (macV_minor_version >= 6):
            self.topIndex = 6
        else:
            self.topIndex = 5

        self.pagesize = 0
        if sys.platform == "sunos5":
            try:
                pgsz = sp.Popen(["pagesize"], stdout=sp.PIPE, close_fds=True).communicate()[0]
                self.pagesize = int(pgsz.strip())
            except Exception:
                # No page size available
                pass
Exemplo n.º 41
0
    def __init__(self, logger):
        Check.__init__(self, logger)
        macV = None
        if sys.platform == 'darwin':
            macV = platform.mac_ver()
            macV_minor_version = int(re.match(r'10\.(\d+)\.?.*', macV[0]).group(1))

        # Output from top is slightly modified on OS X 10.6 (case #28239) and greater
        if macV and (macV_minor_version >= 6):
            self.topIndex = 6
        else:
            self.topIndex = 5

        self.pagesize = 0
        if sys.platform == 'sunos5':
            try:
                pgsz, _, _ = get_subprocess_output(['pagesize'], self.logger)
                self.pagesize = int(pgsz.strip())
            except Exception:
                # No page size available
                pass
Exemplo n.º 42
0
    def __init__(self, logger):
        Check.__init__(self, logger)
        macV = None
        if sys.platform == 'darwin':
            macV = platform.mac_ver()
            macV_minor_version = int(re.match(r'10\.(\d+)\.?.*', macV[0]).group(1))

        # Output from top is slightly modified on OS X 10.6 (case #28239) and greater
        if macV and (macV_minor_version >= 6):
            self.topIndex = 6
        else:
            self.topIndex = 5

        self.pagesize = 0
        if sys.platform == 'sunos5':
            try:
                pgsz, _, _ = get_subprocess_output(['pagesize'], self.logger)
                self.pagesize = int(pgsz.strip())
            except Exception:
                # No page size available
                pass
Exemplo n.º 43
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.mem.free')
     self.gauge('system.mem.used')
     self.gauge('system.mem.total')
     # area of physical memory that stores recently used pages of data
     # for applications
     self.gauge('system.mem.cached')
     # Committed memory is physical memory for which space has been
     # reserved on the disk paging file in case it must be written
     # back to disk
     self.gauge('system.mem.committed')
     # physical memory used by the operating system, for objects
     # that can be written to disk when they are not being used
     self.gauge('system.mem.paged')
     # physical memory used by the operating system for objects that
     # cannot be written to disk, but must remain in physical memory
     # as long as they are allocated.
     self.gauge('system.mem.nonpaged')
     # usable = free + cached
     self.gauge('system.mem.usable')
     self.gauge('system.mem.pct_usable')
Exemplo n.º 44
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.mem.free')
     self.gauge('system.mem.used')
     self.gauge('system.mem.total')
     # area of physical memory that stores recently used pages of data
     # for applications
     self.gauge('system.mem.cached')
     # Committed memory is physical memory for which space has been
     # reserved on the disk paging file in case it must be written
     # back to disk
     self.gauge('system.mem.committed')
     # physical memory used by the operating system, for objects
     # that can be written to disk when they are not being used
     self.gauge('system.mem.paged')
     # physical memory used by the operating system for objects that
     # cannot be written to disk, but must remain in physical memory
     # as long as they are allocated.
     self.gauge('system.mem.nonpaged')
     # usable = free + cached
     self.gauge('system.mem.usable')
     self.gauge('system.mem.pct_usable')
Exemplo n.º 45
0
    def __init__(self, logger):
        Check.__init__(self, logger)
        macV = None
        if sys.platform == 'darwin':
            macV = platform.mac_ver()
            macV_minor_version = int(re.match(r'10\.(\d+)\.?.*', macV[0]).group(1))
        
        # Output from top is slightly modified on OS X 10.6 (case #28239) and greater
        if macV and (macV_minor_version >= 6):
            self.topIndex = 6
        else:
            self.topIndex = 5

        self.pagesize = 0
        if sys.platform == 'sunos5':
            try:
                pgsz = sp.Popen(['pagesize'],
                                        stdout=sp.PIPE,
                                        close_fds=True).communicate()[0]
                self.pagesize = int(pgsz.strip())
            except Exception:
                # No page size available
                pass
Exemplo n.º 46
0
    def __init__(self, logger):
        Check.__init__(self, logger)
        self.mysqlVersion = None
        self.db = None
        self.logger = logger

        # Register metrics
        self.counter("mysqlConnections")
        self.gauge("mysqlCreatedTmpDiskTables")
        self.gauge("mysqlMaxUsedConnections")
        self.gauge("mysqlOpenFiles")
        self.counter("mysqlSlowQueries")
        self.counter("mysqlQuestions")
        self.counter("mysqlQueries")
        self.gauge("mysqlTableLocksWaited")
        self.gauge("mysqlThreadsConnected")
        self.gauge("mysqlSecondsBehindMaster")

        self.counter("mysqlInnodbDataReads")
        self.counter("mysqlInnodbDataWrites")
        self.counter("mysqlInnodbOsLogFsyncs")

        self.counter("mysqlUserTime")
        self.counter("mysqlKernelTime")
Exemplo n.º 47
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.header_re = re.compile(r'([%\\/\-_a-zA-Z0-9]+)[\s+]?')
     self.item_re   = re.compile(r'^([a-zA-Z0-9\/]+)')
     self.value_re  = re.compile(r'\d+\.\d+')
Exemplo n.º 48
0
 def __init__(self, logger):
     Check.__init__(self, logger)
Exemplo n.º 49
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.gauge('system.proc.queue_length')
     self.gauge('system.proc.count')
Exemplo n.º 50
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.gauge('system.proc.queue_length')
     self.gauge('system.proc.count')
Exemplo n.º 51
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.net.bytes_rcvd')
     self.gauge('system.net.bytes_sent')
Exemplo n.º 52
0
 def __init__(self, logger):
     Check.__init__(self, logger)
Exemplo n.º 53
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.logger = logger
     self.gauge('system.net.bytes_rcvd')
     self.gauge('system.net.bytes_sent')
Exemplo n.º 54
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.header_re = re.compile(r'([%\\/\-_a-zA-Z0-9]+)[\s+]?')
     self.item_re = re.compile(r'^([a-zA-Z0-9\/]+)')
     self.value_re = re.compile(r'\d+\.\d+')
Exemplo n.º 55
0
    def __init__(self, logger):
        Check.__init__(self, logger)

        self.networkTrafficStore = {}
        self.networkTrafficStore["last_ts"] = time.time()
        self.networkTrafficStore["current_ts"] = self.networkTrafficStore["last_ts"]
Exemplo n.º 56
0
 def __init__(self, logger):
     Check.__init__(self, logger)
     self.db = None
     self.rrd_path = None
     self.logger = logger
     self.last_ts = {}