def initialize_gatherer(gatherer=None):
 global _gatherer
 if (gatherer is not None):
  LOG.debug(_('using provided stats gatherer %r'), gatherer)
  _gatherer = gatherer
 if (_gatherer is None):
  LOG.debug(_('making a new stats gatherer'))
  mgr = extension.ExtensionManager(namespace='ceilometer.poll.compute', invoke_on_load=True)
  _gatherer = DeletedInstanceStatsGatherer(mgr)
 return _gatherer

def initialize_gatherer ( gatherer = None ) : global _gatherer if ( gatherer is not None ) : LOG . debug ( _ ( 'using provided stats gatherer %r' ) , gatherer ) _gatherer = gatherer if ( _gatherer is None ) : LOG . debug ( _ ( 'making a new stats gatherer' ) ) mgr = extension . ExtensionManager ( namespace = 'ceilometer.poll.compute' , invoke_on_load = True ) _gatherer = DeletedInstanceStatsGatherer ( mgr ) return _gatherer
set the callable used to gather stats for the instance .