7 Video: Cancellation, Context, and Plumbing by Sameer Ajmani

vimeo.com posted by kenny 2861 days ago  

Go makes it easy to start goroutines but doesn't provide any way to stop them. Efficiently canceling unnecessary work is a critical part of making programs scale well. We developed an API called Context to signal request cancelation and provide a way to pass request-scoped data from incoming RPCs to outgoing ones. But now we're faced with the problem of plumbing Contexts into millions of lines of Go code at Google. I'll describe ongoing work that uses static analysis and large-scale refactoring tools to tackle this problem.

Register to comment or vote on this story