Current Path : /usr/lib/python2.7/dist-packages/landscape/monitor/ |
Current File : //usr/lib/python2.7/dist-packages/landscape/monitor/processorinfo.pyc |
Tc @ s d d l Z d d l Z d d l Z d d l m Z d d l m Z d e f d YZ d d d YZ d d d YZ d d d YZ d d d YZ d e f d e f d e f d e f g Z d S( iN( t PluginConfigError( t MonitorPlugint ProcessorInfoc B sw e Z d Z d Z d Z d Z d d d d Z d Z d Z d Z e d Z e d Z d Z d Z RS( s Plugin captures information about the processor(s) in this machine. This plugin runs once per client session. When processor information is retrieved it's compared against the last known processor information, which is saved in persistent storage. A message is only put on the message queue if the latest processor information differs from the last known processor information. The information available from /proc/cpuinfo varies per platform. For example, an Apple PowerMac Dual G5 doesn't contain a vendor ID and provides the processor name in the 'cpu' field, as opposed to the 'model name' field used on x86-based hardware. For reasons such as this, the schema of the data reported by this plugin is flexible. Only 'processor-id' and 'model' are guaranteed to be present. In order to deal with the vagaries of parsing /proc/cpu information on the various platforms we support, message generation is deferred to per-platform message factories. @param delay: Set the starting delay. @param machine_name: The machine name to report. @param source_filename: The filesystem path to read information from. s processor-infot cpui s /proc/cpuinfoc C sJ | | _ | | _ | d k r1 t j d } n | j | | | _ d S( Ni ( t _delayt _source_filenamet Nonet ost unamet _create_cpu_info_readert _cpu_info_reader( t selft delayt machine_namet source_filename( ( sC /usr/lib/python2.7/dist-packages/landscape/monitor/processorinfo.pyt __init__( s c C sU x>