Class: ElasticNotifier::Error
- Defined in:
- lib/elastic_notifier/error.rb
Instance Attribute Summary collapse
-
#attributes ⇒ Object
readonly
Returns the value of attribute attributes.
Instance Method Summary collapse
- #data ⇒ Object
-
#initialize(error, overrides = {}) ⇒ Error
constructor
A new instance of Error.
- #severity ⇒ Object
Methods inherited from Signal
Constructor Details
#initialize(error, overrides = {}) ⇒ Error
Returns a new instance of Error.
5 6 7 8 |
# File 'lib/elastic_notifier/error.rb', line 5 def initialize(error, overrides = {}) super(overrides) @error = error end |
Instance Attribute Details
#attributes ⇒ Object (readonly)
Returns the value of attribute attributes.
3 4 5 |
# File 'lib/elastic_notifier/error.rb', line 3 def attributes @attributes end |
Instance Method Details
#data ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/elastic_notifier/error.rb', line 14 def data { name: @error.class.name, message: @error., backtrace: @error.backtrace } end |
#severity ⇒ Object
10 11 12 |
# File 'lib/elastic_notifier/error.rb', line 10 def severity 'error' end |