Sha256: 0996054b712705a321a01de505b2f600102b40165f99f7ff85f67e835f07d41e

Contents?: true

Size: 329 Bytes

Versions: 3

Compression:

Stored size: 329 Bytes

Contents

require_relative './base'
module Subscribers
  class Metrics < Base

    def process
      payload   = event.payload
      dur   = event.duration
      url = payload[:url]
      http_method = payload[:method].to_s.upcase
      $stderr.puts '[%s] %s %s (%.3f s)' % [url.host, http_method, url.request_uri, dur]
    end

  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
asana_exception_notifier-2.0.1 spec/subscribers/metrics.rb
asana_exception_notifier-2.0.0 spec/subscribers/metrics.rb
asana_exception_notifier-1.1.0 spec/subscribers/metrics.rb