banshee is under active development: collectors will keep changing, and a version you publish will likely need adjustments. For stable use, wait for version 1.0.0.

Examples

banshee/examples-collection/examples/mechanics/

wait

Example: time.wait, two readings within one pass; the CPU usage of a Linux.

  • example
  • time
  • wait
  • cpu
  • ssh

by banshee1 installation1 version

v1Latest

Published on October 27, 2026. First version in this collection.

Waiting within a pass

time.wait waits inside a pass. Here, two readings of the CPU counters of a Linux, five seconds apart, give the CPU usage at the first pass already, where counter.rate waits for the next pass.

How to read it

  • time.wait(5): five seconds, counted in the time the collector is allowed for a pass. A pass that goes beyond it stops, unreachable.
  • cpu_times returns an array of two keys, read as $before['idle']: a function returns one value, and an array carries several.
  • The first line of /proc/stat, cpu, sums every core, in hundredths of a second since the start: idle is idle plus iowait.

To adapt it

  • A wait makes every pass longer: across many probes, counter.rate is lighter (see examples/mechanics/counter-rate).