Class: Sqreen::Metric::Collect
- Defined in:
- lib/sqreen/metrics/collect.rb
Overview
This is an aggregated statistic definition This is a base class to collect metrics in a hash based structure that does not aggregate anything
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#update(key, value) ⇒ Object
from class attr_accessor :aggregate.
Methods inherited from Base
Constructor Details
This class inherits a constructor from Sqreen::Metric::Base
Instance Method Details
#update(key, value) ⇒ Object
from class attr_accessor :aggregate
16 17 18 19 20 21 |
# File 'lib/sqreen/metrics/collect.rb', line 16 def update(key, value) super s = @sample[OBSERVATION_KEY] s[key] ||= [] s[key] << value end |