Examples using... context.Context

Recent
Package sql provides a generic interface around SQL (or SQL-like) databases.
This example demonstrates how a value can be passed to the context and also how to retrieve it if it exists.
This example demonstrates the use of a cancelable context to prevent a goroutine leak. By the end of the example function, the goroutine started by gen will return without leaking.