Class: Hoodoo::Services::Middleware::ExceptionReporting::Payload
- Inherits:
-
Object
- Object
- Hoodoo::Services::Middleware::ExceptionReporting::Payload
- Defined in:
- lib/hoodoo/services/middleware/exception_reporting/exception_reporting.rb
Overview
Implementation detail of Hoodoo::Services::Middleware::ExceptionReporting used to carry multiple parameters describing exception related data through the Hoodoo::Communicators::Pool#communicate mechanism.
Instance Attribute Summary collapse
-
#context ⇒ Object
A Hoodoo::Services::Context instance describing the in-flight request/response cycle, if there is one.
-
#exception ⇒ Object
Exception (or Exception subclass) instance.
-
#rack_env ⇒ Object
Rack environment (the unprocessed, original Hash).
Instance Method Summary collapse
-
#initialize(exception:, rack_env: nil, context: nil) ⇒ Payload
constructor
Initialize this instance with named parameters:.
Constructor Details
#initialize(exception:, rack_env: nil, context: nil) ⇒ Payload
Initialize this instance with named parameters:
exception
-
Exception (or Exception subclass) instance. Mandatory.
rack_env
-
Rack environment hash. Optional.
context
-
Hoodoo::Services::Context instance. Optional.
128 129 130 131 132 |
# File 'lib/hoodoo/services/middleware/exception_reporting/exception_reporting.rb', line 128 def initialize( exception:, rack_env: nil, context: nil ) @exception = exception @rack_env = rack_env @context = context end |
Instance Attribute Details
#context ⇒ Object
A Hoodoo::Services::Context instance describing the in-flight request/response cycle, if there is one. May be nil
.
120 121 122 |
# File 'lib/hoodoo/services/middleware/exception_reporting/exception_reporting.rb', line 120 def context @context end |
#exception ⇒ Object
Exception (or Exception subclass) instance.
111 112 113 |
# File 'lib/hoodoo/services/middleware/exception_reporting/exception_reporting.rb', line 111 def exception @exception end |
#rack_env ⇒ Object
Rack environment (the unprocessed, original Hash). May be nil
.
115 116 117 |
# File 'lib/hoodoo/services/middleware/exception_reporting/exception_reporting.rb', line 115 def rack_env @rack_env end |