Class | OpenWFE::ProcessError |
In: |
lib/openwfe/expool/errorjournal.rb
|
Parent: | Object |
Encapsulating process error information.
Instances of this class may be used to replay_at_error
date | [R] | When did the error occur. |
error_class | [R] | The error class (String) of the top level error |
fei | [R] | The FlowExpressionId instance uniquely pointing at the expression which ‘failed’. |
message | [R] | Generally something like :apply or :reply |
stacktrace | [R] | The String stack trace of the error. |
workitem | [R] | The workitem accompanying the message (apply(workitem) / reply (workitem)). |
# File lib/openwfe/expool/errorjournal.rb, line 89 89: def initialize (*args) 90: 91: @date = Time.new 92: @fei, @message, @workitem, @error_class, @stacktrace = args 93: end
Returns true if the other instance is a ProcessError and is the same error as this one.
# File lib/openwfe/expool/errorjournal.rb, line 134 134: def == (other) 135: return false unless other.is_a?(ProcessError) 136: return to_s == other.to_s 137: # 138: # a bit costly but as it's only used by resume_process()... 139: end
Produces a human readable version of the information in the ProcessError instance.
# File lib/openwfe/expool/errorjournal.rb, line 109 109: def to_s 110: s = "" 111: s << "-- #{self.class.name} --\n" 112: s << " date : #{@date}\n" 113: s << " fei : #{@fei}\n" 114: s << " message : #{@message}\n" 115: s << " workitem : ...\n" 116: s << " error_class : #{@error_class}\n" 117: s << " stacktrace : #{@stacktrace[0, 80]}\n" 118: s 119: end
Returns the parent workflow instance id (process id) of this ProcessError instance.
# File lib/openwfe/expool/errorjournal.rb, line 99 99: def wfid 100: @fei.parent_wfid 101: end