Expand description
Process-global packet-flow diagnostic counters for the throughput stress harness.
These counters were originally defined in hopr-utils::parallelize, but they encode
HOPR session/routing domain concepts (session inbox, routing resolution, SPHINX encode
stage) rather than generic parallelisation primitives. They therefore live here in the
transport-session crate instead of the generic hopr-utilities crate.
Each counter is a plain process-global atomic, incremented on hot paths across the transport/session pipeline and read (as deltas) by the load generator. They are not gated on any feature so they are available in every build, including test builds.
Statics§
- APP_
INCOMING_ TIMEOUT_ DROPS - Cumulative count of packets dropped by
forward_to_timeout(app_incoming)at the ingress pipeline becausetx_from_protocolwas full for longer thanQUEUE_SEND_TIMEOUT(50 ms). - DISPATCH_
MESSAGE_ CALLS - Cumulative count of calls to
smgr.dispatch_messagein SessionsManagement(0). Non-zero means packets are reaching the session manager dispatcher. - ENCODE_
STAGE_ ENTRIES - Cumulative count of packets that entered the SPHINX encode stage (spawn_encode_blocking called).
- ROUTING_
RESOLUTION_ ATTEMPTS - Cumulative count of packets that successfully entered the routing resolution stage.
- ROUTING_
RESOLUTION_ FAILURES - Cumulative count of packets that failed path/routing resolution before encoding.
- ROUTING_
RESOLUTION_ SURB_ TIMEOUTS - Cumulative count of outgoing packets dropped because their return route still had no SURB when the resolution wait ran out.
- SESSION_
INBOX_ DROPS - Cumulative count of application data packets dropped because the session inbox
channel was full (
try_sendreturnedTrySendError::Full). - SESSION_
UNKNOWN_ DATA_ DROPS - Cumulative count of data packets dropped because no matching session slot was
found in the session manager (
UnknownData/ unestablished-session path). - SESSION_
UNRELATED_ DATA_ DISPATCHES - Cumulative count of data packets dispatched as “unrelated” — reached dispatch_message but matched neither the session protocol tag nor any session application tag.
Functions§
- app_
incoming_ timeout_ drop_ count - Returns the cumulative app-incoming timeout drop count.
- dispatch_
message_ call_ count - Returns the cumulative dispatch_message call count.
- encode_
stage_ entry_ count - Returns the cumulative encode stage entry count.
- routing_
resolution_ attempt_ count - Returns the cumulative routing resolution attempt count.
- routing_
resolution_ failure_ count - Returns the cumulative routing resolution failure count.
- routing_
resolution_ surb_ timeout_ count - Returns the cumulative count of packets dropped after waiting in vain for a return SURB.
- session_
inbox_ drop_ count - Returns the cumulative session inbox drop count.
- session_
unknown_ data_ drop_ count - Returns the cumulative UnknownData drop count.
- session_
unrelated_ dispatch_ count - Returns the cumulative unrelated dispatch count.