Class: Source::Source

Inherits:
Object
  • Object
show all
Includes:
Helpers
Defined in:
lib/source/source.rb

Overview

Parent Collector Source class Use this class directly when the source does not need any overrides

Direct Known Subclasses

Bom, Ceilometer, Demowave, Iptraffic, Nagios, Newrelic

Constant Summary

Constants included from Helpers

Helpers::REDIS_KEY

Instance Method Summary collapse

Methods included from Helpers

#data_sanitize, #delete_metrics_cache, #get_json, #init_lib, #init_source, #init_store, #interpolate, #is_up?, #json_metrics, #json_metrics_list, #keysplit, #mandatory_param, #optional_param, #origin_settings, #redis_conn, #top_tail_pad

Constructor Details

#initialize(origin_id, settings) ⇒ Source


7
8
9
10
# File 'lib/source/source.rb', line 7

def initialize origin_id, settings
	@origin_id = origin_id
	@settings = settings
end

Instance Method Details

#metaadd(m) ⇒ Object

Add any source-specific metadata to the string


13
14
15
# File 'lib/source/source.rb', line 13

def metaadd m
	return m
end

#titleize(str) ⇒ Object

Make the title of the graph human-readable Default: return the string itself as the title


19
20
21
# File 'lib/source/source.rb', line 19

def titleize str
	return str
end