Skip to content

.Net Processes - Facilitate Parallel Execution of LocalProcess#9463

Merged
crickman merged 4 commits intomainfrom
process-parallel-execution
Oct 30, 2024
Merged

.Net Processes - Facilitate Parallel Execution of LocalProcess#9463
crickman merged 4 commits intomainfrom
process-parallel-execution

Conversation

@crickman
Copy link
Contributor

@crickman crickman commented Oct 29, 2024

Motivation and Context

When using async/await, there is no guarantee that the method will actually run asynchronously. The internal implementation is free to return using a completely synchronous path.

Description

Add Task.Yield() when starting LocalProcess to encourage the use of a separate sychronization context from the current one.

Contribution Checklist

@crickman crickman added bug Something isn't working PR: ready for review All feedback addressed, ready for reviews .NET Issue or Pull requests regarding .NET code experimental Associated with an experimental feature enhancement processes labels Oct 29, 2024
@crickman crickman self-assigned this Oct 29, 2024
@crickman crickman requested a review from a team as a code owner October 29, 2024 21:27
@crickman crickman changed the title .Net Agents - Facilitate Parallel Execution of Processes .Net Processes - Facilitate Parallel Execution of Processes Oct 29, 2024
@crickman crickman changed the title .Net Processes - Facilitate Parallel Execution of Processes .Net Processes - Facilitate Parallel Execution of LocalProcess Oct 29, 2024
Copy link
Contributor

@esttenorio esttenorio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the beauty of a powerful 1 line change

@crickman crickman added this pull request to the merge queue Oct 30, 2024
Merged via the queue into main with commit c371705 Oct 30, 2024
@crickman crickman deleted the process-parallel-execution branch October 30, 2024 17:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working enhancement experimental Associated with an experimental feature .NET Issue or Pull requests regarding .NET code PR: ready for review All feedback addressed, ready for reviews processes

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants