Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Queue write operations for Start-* cmdlets and hook up diagnostics #3222

Merged
merged 7 commits into from
May 9, 2023

Conversation

msftrubengu
Copy link
Contributor

@msftrubengu msftrubengu commented May 4, 2023

When a Start-* cmdlet starts its operation it won't write to any PowerShell stream because control is returned back to the user almost immediately. This changes queue messages to be then displayed at Continue-* time. This way, we will have all the messages in the appropriate order. It applies for WriteDebug, WriteVerbose, WriteWarning, WriteError and WriteProgress.

WriteProgress will only be called when the activity hasn't been completed. A caller must use AsyncCommand.GetNewProgressActivityId to generate a new activity id.

Microsoft Reviewers: Open in CodeFlow

@msftrubengu msftrubengu requested a review from a team as a code owner May 4, 2023 23:47
@msftrubengu msftrubengu changed the title Queue write operations for Start-* cmdlets Queue write operations for Start-* cmdlets and hook up diagnostics May 5, 2023
@github-actions

This comment has been minimized.

(boolStr[3] == 's' || boolStr[3] == 'S') &&
(boolStr[4] == 'e' || boolStr[4] == 'E'))
{
return true;
Copy link
Member

Choose a reason for hiding this comment

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

I don't see the value in explicitly checking for 0/NO/FALSE when the default return value is the same.

@msftrubengu msftrubengu merged commit fee1b43 into microsoft:master May 9, 2023
@msftrubengu msftrubengu deleted the concurrentqueue branch August 14, 2023 22:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants