Class: Sidekiq::Metrics::Query::Result

Inherits:
Struct
  • Object
show all
Defined in:
lib/sidekiq/metrics/query.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(granularity = :minutely) ⇒ Result

Returns a new instance of Result.



117
118
119
120
121
122
# File 'lib/sidekiq/metrics/query.rb', line 117

def initialize(granularity = :minutely)
  super
  self.granularity = granularity
  self.marks = []
  self.job_results = Hash.new { |h, k| h[k] = JobResult.new(granularity) }
end

Instance Attribute Details

#ends_atObject

Returns the value of attribute ends_at

Returns:

  • (Object)

    the current value of ends_at



116
117
118
# File 'lib/sidekiq/metrics/query.rb', line 116

def ends_at
  @ends_at
end

#granularityObject

Returns the value of attribute granularity

Returns:

  • (Object)

    the current value of granularity



116
117
118
# File 'lib/sidekiq/metrics/query.rb', line 116

def granularity
  @granularity
end

#job_resultsObject

Returns the value of attribute job_results

Returns:

  • (Object)

    the current value of job_results



116
117
118
# File 'lib/sidekiq/metrics/query.rb', line 116

def job_results
  @job_results
end

#marksObject

Returns the value of attribute marks

Returns:

  • (Object)

    the current value of marks



116
117
118
# File 'lib/sidekiq/metrics/query.rb', line 116

def marks
  @marks
end

#sizeObject

Returns the value of attribute size

Returns:

  • (Object)

    the current value of size



116
117
118
# File 'lib/sidekiq/metrics/query.rb', line 116

def size
  @size
end

#starts_atObject

Returns the value of attribute starts_at

Returns:

  • (Object)

    the current value of starts_at



116
117
118
# File 'lib/sidekiq/metrics/query.rb', line 116

def starts_at
  @starts_at
end