util

package
v0.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 11, 2026 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetTimeoutContext

func GetTimeoutContext(ctx context.Context) (context.Context, context.CancelFunc)

GetTimeoutContext returns a context for a single call to a backend. It keeps the values of ctx -- the trace and the baggage of the request that caused the call -- and puts the usual timeout on it.

func WriteContext added in v0.2.0

func WriteContext(ctx context.Context) context.Context

WriteContext keeps the values of ctx but drops its cancellation.

Creating, updating and deleting an instance each write to the deployment backend and to the database, and the two have to agree. A request cancelled between the two writes would leave a container running that no instance points at, or an instance whose container is gone -- which the startup restore then recreates. The read paths stay cancellable.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL