Sha256: 4e4779a0326bca59a31bc666c7d175550d9d9faad1c5630924452056750c7332
Contents?: true
Size: 604 Bytes
Versions: 7
Compression:
Stored size: 604 Bytes
Contents
module PulseMeter module Sensor module Timelined class ZSetBased < Timeline def update(_) end def calculate(key) 0 end def aggregate_event(key, value) command_aggregator.zadd(key, value, "#{value}::#{uniqid}") update(key) end def summarize(key) count = redis.zcard(key) if count > 0 calculate(key, count) else nil end end private def deflate(value) value.to_f end end end end end
Version data entries
7 entries across 7 versions & 1 rubygems