Class: Aws::Xray::Error
- Inherits:
-
Struct
- Object
- Struct
- Aws::Xray::Error
- Defined in:
- lib/aws/xray/error.rb
Constant Summary collapse
- MAX_BACKTRACE_SIZE =
250
Instance Attribute Summary collapse
-
#cause ⇒ Object
Returns the value of attribute cause.
-
#e ⇒ Object
Returns the value of attribute e.
-
#error ⇒ Object
Returns the value of attribute error.
-
#fault ⇒ Object
Returns the value of attribute fault.
-
#remote ⇒ Object
Returns the value of attribute remote.
-
#throttle ⇒ Object
Returns the value of attribute throttle.
Instance Method Summary collapse
Instance Attribute Details
#cause ⇒ Object
Returns the value of attribute cause
5 6 7 |
# File 'lib/aws/xray/error.rb', line 5 def cause @cause end |
#e ⇒ Object
Returns the value of attribute e
5 6 7 |
# File 'lib/aws/xray/error.rb', line 5 def e @e end |
#error ⇒ Object
Returns the value of attribute error
5 6 7 |
# File 'lib/aws/xray/error.rb', line 5 def error @error end |
#fault ⇒ Object
Returns the value of attribute fault
5 6 7 |
# File 'lib/aws/xray/error.rb', line 5 def fault @fault end |
#remote ⇒ Object
Returns the value of attribute remote
5 6 7 |
# File 'lib/aws/xray/error.rb', line 5 def remote @remote end |
#throttle ⇒ Object
Returns the value of attribute throttle
5 6 7 |
# File 'lib/aws/xray/error.rb', line 5 def throttle @throttle end |
Instance Method Details
#to_h ⇒ Object
8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/aws/xray/error.rb', line 8 def to_h h = { error: error, throttle: throttle, fault: fault } if cause h[:cause] = cause.to_h(remote: remote) end # Overwrite cause because recording exception is more important. if e h[:cause] = build_cause_from_exception(e, remote) end h end |