lib/metricstore/updater.rb
# This must only be called by the EM reactor thread
This must only be called by the EM reactor thread
This must only be called by the EM reactor thread
def pend_update(key, data, ttl, errors)
      pending = @pending_updates[key]
      if pending.nil?
        @pending_updates[key] = {:data => prepare_data(data), :ttl => ttl, :errors => errors}
      else
        pending[:data]    = consolidate_data(pending[:data], prepare_data(data))
        pending[:ttl]     = max_ttl(ttl, pending[:ttl])
        pending[:errors] += errors
      end
    rescue => e
      handle_error(e)
    end
def pend_update ( key , data , ttl , errors ) pending = @pending_updates [ key ] if pending . nil? @pending_updates [ key ] = { :data => prepare_data ( data ) , :ttl => ttl , :errors => errors } else pending [ :data ] = consolidate_data ( pending [ :data ] , prepare_data ( data ) ) pending [ :ttl ] = max_ttl ( ttl , pending [ :ttl ] ) pending [ :errors ] += errors end rescue => e handle_error ( e ) end
This must only be called by the EM reactor thread
This must only be called by the EM reactor thread
key
<not_specific>
data
<not_specific>
ttl
<not_specific>
errors
<not_specific>