Help us shape the future of Go! Take the 2026 Go Developer Survey

kernel

package module
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2026 License: Apache-2.0 Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GuardAction

func GuardAction(ledger cost.Reserver, estimateMicros int64) action.AnyHook

GuardAction integrates any cost.Reserver with a Kernel action. The adapter reserves before execution, releases on failure/cancel/panic, and records a successful reported cost. Terminal accounting is deliberately isolated from the request context: Commit and Release use a fresh background context with a five-second timeout, so a canceled request cannot strand a distributed reservation. Applications that need terminal errors returned to their caller should use cost.Reserver directly rather than a void hook.

Types

This section is empty.

Jump to

Keyboard shortcuts

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