Class: Oink::Reports::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/oink/reports/base.rb

Constant Summary collapse

FORMATS =
%w[verbose short-summary summary]
FORMAT_ALIASES =
{ "v" => "verbose", "ss" => "short-summary", "s" => "summary" }
HODEL_LOG_FORMAT_REGEX =
/^(\w+ \d{2} \d{2}:\d{2}:\d{2})/

Instance Method Summary collapse

Constructor Details

#initialize(input, threshold, options = {}) ⇒ Base

Returns a new instance of Base.



9
10
11
12
13
14
15
16
17
18
# File 'lib/oink/reports/base.rb', line 9

def initialize(input, threshold, options = {})
  @inputs = Array(input)
  @threshold = threshold
  @format = options[:format] || :short_summary

  @pids = {}
  @bad_actions = {}
  @bad_actions_averaged = {}
  @bad_requests = PriorityQueue.new(10)
end