behavior

package
v0.0.10 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2026 License: Apache-2.0 Imports: 0 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.

Documentation

Overview

Package behavior holds the behavior labs: whole networks booted through the node's own assembly on the userspace fabric, run inside synctest bubbles at the daemon's own pacing, each asserting what the selection policy makes of the network across many windows — that a cut heals, that the link set settles, that every pair then reaches over its chosen path, the path the source's lease of the destination holds. The labs run without the race detector: a replay of virtual minutes to hours repeats code the e2e labs of internal/testnetwork already run under the detector, at several times the wall time.

Beside the labs, benchmarks grade the same networks by the paths they serve: every pair's chosen path against the shortest paths the fabric's delays allow, the segment records no chosen path joins, and the links a single cut would need, once settled and through the network's answer to a link cut and restored, a delay raised or lowered, and a link's loss swept up and back down; and the hub lab's flows, which load a thin and well-placed node's uplink past its rate, report what the flows, the uplink, the leases, and the links met. They are skipped unless CION_BENCH is set, and each prints benchmark result lines on standard output for benchstat:

CION_BENCH=1 go test -run Bench -count=10 -v ./internal/testnetwork/behavior/

Jump to

Keyboard shortcuts

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