Added UnfinishedPolicy option to [WorkflowSignal] and [WorkflowUpdate] attributes and defaulted to WarnAndAbandon
Added unfinished policy option to WorkflowSignalDefinition and WorkflowUpdateDefinition classes (used by manual handler registration)
Updated workflow logic to send a warning to the logger if warnable signal and/or update handlers remain on workflow exit
Made sure to properly instantiate the workflow class before checking for update/query handler presence so manual ones can be defined in the constructor (not needed for signals because they are buffered, and also changing that part of current code is non-deterministic)
Added tests for all permutations of workflow exit (success, failure, cancel), handler (update, signal), unfinished policy (default/warn, abandon), workflow wait for all-complete (true, false), and handler registration approach (on method, manual)
What was changed
Workflow.AllHandlersFinished
bool propertyHandlerUnfinishedPolicy
enumUnfinishedPolicy
option to[WorkflowSignal]
and[WorkflowUpdate]
attributes and defaulted toWarnAndAbandon
WorkflowSignalDefinition
andWorkflowUpdateDefinition
classes (used by manual handler registration)Checklist