Sha256: 7d9bb3f89f4c1f9cbbf474163e8aca834b153d79d47d7a6ccf537b5c659e31a9
Contents?: true
Size: 828 Bytes
Versions: 10
Compression:
Stored size: 828 Bytes
Contents
module Chillout class EventDataBuilder def initialize(config) @config = config end def build_from_creations_container(creations_container, timestamp) { :metric => "creations", :timestamp => timestamp, :content => { :creations => build_creations_content(creations_container), :environment => @config.environment }, :notifier => build_notifier } end def build_creations_content(creations_container) creation_tuples = creations_container.resource_keys.map do |key| [key, creations_container[key]] end Hash[creation_tuples] end def build_notifier { :name => @config.notifier_name, :version => @config.version, :url => @config.notifier_url } end end end
Version data entries
10 entries across 10 versions & 1 rubygems