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

[17.12] Prevent contention between CancelAllSubmissions and EndBuild #10745

Merged
merged 6 commits into from
Oct 4, 2024

Conversation

JanKrivanek
Copy link
Member

@JanKrivanek JanKrivanek commented Oct 2, 2024

Fixes #10709

Summary

VS hangs during solution close - turns out to be caused by hang in BuildManager.EndBuild
There are almost 3k over 4k (and counting) cases hit in wild on 17.11 (details)

It turns out to be a contention between CancelAllSubmissions and EndBuild (for the state of _buildManagerState) - more details in the bug: #10709 (comment)

Customer Impact

High rate of hangs during solution closes (either during VS closing or opening different solution from VS with already opened solution)

Regression?

No, but some other recent timing changes (possibly speedups) made this much more prelevant.

Testing

Tailored unit test (reliably simulating the hang if fix is not present).
Existing unit tests.
Manual testing in VS, with manualy freezing/thawing threads to simulate corner cases

Risk

Low - it allows resubmission of cancelation requests that are internaly otherwise idempotent already.

Changes Made

CancelAllSubmissions is allowed to be executed even if EndBuild was initiated

@JanKrivanek JanKrivanek merged commit 4ae11fa into vs17.12 Oct 4, 2024
10 checks passed
@JanKrivanek JanKrivanek deleted the proto/solution-close-hang-fix-17-12 branch October 4, 2024 05:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants