Skip to content

Add checks to ensure that we don't have any unexpected exceptions corrupting state#63133

Merged
CyrusNajmabadi merged 3 commits intodotnet:mainfrom
CyrusNajmabadi:exceptionChecks
Aug 2, 2022
Merged

Add checks to ensure that we don't have any unexpected exceptions corrupting state#63133
CyrusNajmabadi merged 3 commits intodotnet:mainfrom
CyrusNajmabadi:exceptionChecks

Conversation

@CyrusNajmabadi
Copy link
Copy Markdown
Contributor

Followup to #63132

@CyrusNajmabadi CyrusNajmabadi requested a review from a team as a code owner August 2, 2022 16:56
@ghost ghost added the Area-IDE label Aug 2, 2022
@CyrusNajmabadi CyrusNajmabadi requested a review from dibarbet August 2, 2022 16:56
assetProvider, solutionChecksum, workspaceVersion, updatePrimaryBranch);
solutionTask = inFlightSolution.PreferredSolutionTask_NoLock;
await DecrementInFlightCountAsync(inFlightSolution).ConfigureAwait(false);
}
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

broke this code into 3 helpers:

  1. acquire the solution. this updates state and has checks to make sure that happens successfully. It must always run to completion.
  2. process the solution. this is allowed to technically fail for any reason (and cancellation failure is totally ok). failure must not leave this type in an inconsistent state.
  3. cleanup. this updates state and has checks to make sure that happens successfully. It must always run to completion.

@CyrusNajmabadi CyrusNajmabadi merged commit 25f26ae into dotnet:main Aug 2, 2022
@ghost ghost added this to the Next milestone Aug 2, 2022
@CyrusNajmabadi CyrusNajmabadi deleted the exceptionChecks branch August 2, 2022 22:57
@dibarbet dibarbet modified the milestones: Next, 17.4 P2 Sep 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants