forked from cockroachdb/cockroach
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
singleflight: spruce up singleflight
This patch improves singleflight with a couple of features that were done manually by most callers. The singleflight now optionally makes a flight's context not respond to the cancelation of the caller's ctx, the flights now run in stopper tasks, and stopper quiescence cancels the flights' contexts. The callers were doing some of these things, but inconsistently. Also, the flights now get a tracing span and callers that join an existing span get a copy of the recording of the flight leader. We've wanted this multiple times when debugging, for example in the context of table descriptor lease acquisitions and range descriptor resolving. The interface for getting the results out of DoChan() had to change a bit as a result. Release note: None
- Loading branch information
1 parent
d2e0051
commit 5129578
Showing
36 changed files
with
1,035 additions
and
518 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.