Class: OpenWFE::BaseHistory
- Inherits:
-
Object
- Object
- OpenWFE::BaseHistory
- Includes:
- FeiMixin, HistoryMixin
- Defined in:
- lib/openwfe/expool/history.rb
Overview
A base implementation for InMemoryHistory and FileHistory.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#entries ⇒ Object
readonly
Returns the value of attribute entries.
Attributes included from ServiceMixin
Attributes included from Contextual
Instance Method Summary collapse
-
#initialize(service_name, application_context) ⇒ BaseHistory
constructor
A new instance of BaseHistory.
- #log(event, *args) ⇒ Object
Methods included from HistoryMixin
Methods included from ServiceMixin
Methods included from Contextual
#get_work_directory, #init_service, #lookup
Methods included from Logging
#ldebug, #ldebug_callstack, #lerror, #lfatal, #linfo, #llog, #lunknown, #lwarn
Methods included from OwfeServiceLocator
#get_engine, #get_error_journal, #get_expool, #get_expression_map, #get_expression_pool, #get_expression_storage, #get_expression_storages, #get_journal, #get_participant_map, #get_scheduler, #get_wfid_generator
Constructor Details
#initialize(service_name, application_context) ⇒ BaseHistory
Returns a new instance of BaseHistory.
79 80 81 82 83 84 |
# File 'lib/openwfe/expool/history.rb', line 79 def initialize (service_name, application_context) super() service_init(service_name, application_context) end |
Instance Attribute Details
#entries ⇒ Object (readonly)
Returns the value of attribute entries.
77 78 79 |
# File 'lib/openwfe/expool/history.rb', line 77 def entries @entries end |
Instance Method Details
#log(event, *args) ⇒ Object
86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 |
# File 'lib/openwfe/expool/history.rb', line 86 def log (event, *args) return if event == :update return if event == :reschedule return if event == :stop msg = "#{Time.now.to_s} -- " msg << event.to_s if args.length > 0 fei = extract_fei args[0] msg << " #{fei.to_s}" end #msg << " #{args[1].to_s}" # if args.length > 1 @output << msg + "\n" end |