Discover Packages
github.com/aofei/wirehop
internal
retention
package
Version:
v0.2.0
Opens a new window with list of versions in this module.
Published: Sep 9, 2026
License: MIT
Opens a new window with license information.
Imports: 2
Opens a new window with list of imports.
Imported by: 0 modules, 0 packages
The first number is the count of modules that contain a package that imports this one.
The module count is a better indicator of popularity than the package count.
A module with 100 importing packages is counted only once instead of 100 times,
reflecting the fact that the choice to use the package was likely made only once,
not 100 times.
A '?' means that the value hasn't been computed yet.
Opens a new window with list of known importers.
Documentation
Documentation
¶
Package retention implements process-wide packet retention accounting.
Budget accounts retained packet capacity shared by independent queues.
NewBudget returns an empty aggregate retention budget.
Release returns previously reserved capacity to the budget.
Reserve retains capacity only when both aggregate limits permit it.
ResizeBytes changes the byte charge of retained capacity without changing its packet charge.
Usage returns the current packet and byte counts, sampled independently.
type Limits struct {
Packets int
Bytes int
}
Limits bound aggregate retained work by packet count and accounted bytes.
type Usage struct {
Packets int
Bytes int
}
Usage is one point-in-time aggregate retention measurement.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.