Class: Henry::Execution
- Inherits:
-
Object
- Object
- Henry::Execution
- Defined in:
- lib/henry/execution.rb
Overview
Henry Execution
Instance Attribute Summary collapse
-
#backtrace ⇒ Object
Accessors for task_name, code, message, output and backtrace.
-
#code ⇒ Object
Accessors for task_name, code, message, output and backtrace.
-
#description ⇒ Object
Accessors for task_name, code, message, output and backtrace.
-
#log ⇒ Object
Accessors for task_name, code, message, output and backtrace.
-
#message ⇒ Object
Accessors for task_name, code, message, output and backtrace.
-
#output ⇒ Object
Accessors for task_name, code, message, output and backtrace.
-
#params ⇒ Object
Accessors for task_name, code, message, output and backtrace.
-
#task_name ⇒ Object
Accessors for task_name, code, message, output and backtrace.
Instance Method Summary collapse
-
#report ⇒ Hash
Returns the json ready hash report of the Task Execution.
-
#set(key, value) ⇒ Object
Sets the given value under the map key.
Instance Attribute Details
#backtrace ⇒ Object
Accessors for task_name, code, message, output and backtrace.
7 8 9 |
# File 'lib/henry/execution.rb', line 7 def backtrace @backtrace end |
#code ⇒ Object
Accessors for task_name, code, message, output and backtrace.
7 8 9 |
# File 'lib/henry/execution.rb', line 7 def code @code end |
#description ⇒ Object
Accessors for task_name, code, message, output and backtrace.
7 8 9 |
# File 'lib/henry/execution.rb', line 7 def description @description end |
#log ⇒ Object
Accessors for task_name, code, message, output and backtrace.
7 8 9 |
# File 'lib/henry/execution.rb', line 7 def log @log end |
#message ⇒ Object
Accessors for task_name, code, message, output and backtrace.
7 8 9 |
# File 'lib/henry/execution.rb', line 7 def @message end |
#output ⇒ Object
Accessors for task_name, code, message, output and backtrace.
7 8 9 |
# File 'lib/henry/execution.rb', line 7 def output @output end |
#params ⇒ Object
Accessors for task_name, code, message, output and backtrace.
7 8 9 |
# File 'lib/henry/execution.rb', line 7 def params @params end |
#task_name ⇒ Object
Accessors for task_name, code, message, output and backtrace.
7 8 9 |
# File 'lib/henry/execution.rb', line 7 def task_name @task_name end |
Instance Method Details
#report ⇒ Hash
Returns the json ready hash report of the Task Execution
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/henry/execution.rb', line 12 def report { name: self.task_name, code: self.code, message: self., description: self.description, returnedData: map.merge({ output: self.output, backtrace: self.backtrace }), log: self.log, worker: `hostname`.strip, parameters: self.params||{} } end |
#set(key, value) ⇒ Object
Sets the given value under the map key.
32 33 34 |
# File 'lib/henry/execution.rb', line 32 def set(key,value) self.map[key.to_sym] = value end |