Class: Anomonitor::Jobs::Row
- Inherits:
-
Struct
- Object
- Struct
- Anomonitor::Jobs::Row
- Defined in:
- lib/anomonitor/jobs/row.rb
Instance Attribute Summary collapse
-
#detail ⇒ Object
Returns the value of attribute detail.
-
#error ⇒ Object
Returns the value of attribute error.
-
#failed_at ⇒ Object
Returns the value of attribute failed_at.
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
-
#queue ⇒ Object
Returns the value of attribute queue.
-
#run_at ⇒ Object
Returns the value of attribute run_at.
-
#source ⇒ Object
Returns the value of attribute source.
-
#status ⇒ Object
Returns the value of attribute status.
-
#tags ⇒ Object
Returns the value of attribute tags.
-
#tenant ⇒ Object
Returns the value of attribute tenant.
Instance Method Summary collapse
Instance Attribute Details
#detail ⇒ Object
Returns the value of attribute detail
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def detail @detail end |
#error ⇒ Object
Returns the value of attribute error
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def error @error end |
#failed_at ⇒ Object
Returns the value of attribute failed_at
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def failed_at @failed_at end |
#id ⇒ Object
Returns the value of attribute id
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def id @id end |
#name ⇒ Object
Returns the value of attribute name
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def name @name end |
#queue ⇒ Object
Returns the value of attribute queue
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def queue @queue end |
#run_at ⇒ Object
Returns the value of attribute run_at
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def run_at @run_at end |
#source ⇒ Object
Returns the value of attribute source
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def source @source end |
#status ⇒ Object
Returns the value of attribute status
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def status @status end |
#tags ⇒ Object
Returns the value of attribute tags
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def @tags end |
#tenant ⇒ Object
Returns the value of attribute tenant
5 6 7 |
# File 'lib/anomonitor/jobs/row.rb', line 5 def tenant @tenant end |
Instance Method Details
#detail_text ⇒ Object
23 24 25 26 27 |
# File 'lib/anomonitor/jobs/row.rb', line 23 def detail_text return nil if detail.nil? || detail.empty? detail.map { |k, v| "#{k}: #{v}" }.join("\n") end |
#sort_at ⇒ Object
19 20 21 |
# File 'lib/anomonitor/jobs/row.rb', line 19 def sort_at failed_at || run_at || Time.at(0) end |