Skip to content

Commit

Permalink
Workflow completion command reordering (#270)
Browse files Browse the repository at this point in the history
Fixes #249
  • Loading branch information
cretz authored Jun 11, 2024
1 parent c299cec commit 3c6c7ac
Show file tree
Hide file tree
Showing 12 changed files with 266 additions and 189 deletions.
166 changes: 39 additions & 127 deletions src/Temporalio/Bridge/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion src/Temporalio/Worker/TemporalWorker.cs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,8 @@ public TemporalWorker(IWorkerClient client, TemporalWorkerOptions options)
OnTaskStarting: options.OnTaskStarting,
OnTaskCompleted: options.OnTaskCompleted,
RuntimeMetricMeter: MetricMeter,
WorkerLevelFailureExceptionTypes: options.WorkflowFailureExceptionTypes));
WorkerLevelFailureExceptionTypes: options.WorkflowFailureExceptionTypes,
DisableCompletionCommandReordering: options.DisableWorkflowCompletionCommandReordering));
}
}

Expand Down
9 changes: 9 additions & 0 deletions src/Temporalio/Worker/TemporalWorkerOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,15 @@ public TemporalWorkerOptions()
internal Func<WorkflowInstanceDetails, IWorkflowInstance> WorkflowInstanceFactory { get; set; } =
DefaultWorkflowInstanceFactory;

/// <summary>
/// Gets or sets a value indicating whether the workflow completion command reordering will
/// apply.
/// </summary>
/// <remarks>
/// This is visible for testing only.
/// </remarks>
internal bool DisableWorkflowCompletionCommandReordering { get; set; }

/// <summary>
/// Add the given delegate with <see cref="ActivityAttribute" /> as an activity. This is
/// usually a method reference.
Expand Down
Loading

0 comments on commit 3c6c7ac

Please sign in to comment.