llarp::path
Classes
| Name | |
|---|---|
| struct | llarp::path::Builder |
| class | llarp::path::BuildLimiter limiter for path builds prevents overload and such |
| struct | llarp::path::BuildStats Stats about all our path builds. |
| struct | llarp::path::IHopHandler |
| struct | llarp::path::Path A path we made. |
| struct | llarp::path::PathContext |
| struct | llarp::path::PathHopConfig configuration for a single hop when building a path |
| struct | llarp::path::PathSet a set of paths owned by an entity |
| struct | llarp::path::TransitHop |
| struct | llarp::path::TransitHopInfo |
Types
| Name | |
|---|---|
| enum | PathStatus { ePathBuilding, ePathEstablished, ePathTimeout, ePathFailed, ePathIgnore, ePathExpired} status of a path |
| using std::shared_ptr< IHopHandler > | HopHandler_ptr |
| typedef std::shared_ptr< TransitHop > | TransitHop_ptr |
| using std::shared_ptr< Builder > | Builder_ptr |
| using int | PathRole the role of this path can fulfill |
| typedef std::shared_ptr< Path > | Path_ptr |
| using std::shared_ptr< PathSet > | PathSet_ptr |
Functions
| Name | |
|---|---|
| bool | operator<(const PathHopConfig & lhs, const PathHopConfig & rhs) |
| bool | operator==(const TransitHopInfo & lhs, const TransitHopInfo & rhs) |
| bool | operator!=(const TransitHopInfo & lhs, const TransitHopInfo & rhs) |
| bool | operator<(const TransitHopInfo & lhs, const TransitHopInfo & rhs) |
Attributes
| Name | |
|---|---|
| constexpr std::size_t | max_len maximum path length |
| constexpr std::size_t | default_len default path length |
| constexpr std::size_t | pad_size pad messages to the nearest this many bytes |
| constexpr std::chrono::milliseconds | default_lifetime default path lifetime in ms |
| constexpr std::chrono::milliseconds | min_intro_lifetime minimum into lifetime we will advertise |
| constexpr auto | intro_spread_slices number of slices of path lifetime to spread intros out via |
| constexpr std::chrono::milliseconds | intro_path_spread spacing frequency at which we try to build paths for introductions |
| constexpr std::chrono::milliseconds | intro_stale_threshold how long away from expiration in millseconds do we consider an intro to become stale |
| constexpr std::size_t | min_intro_paths Minimum paths to keep around for intros; mainly used at startup (the spread, above, should be able to maintain more than this number of paths normally once things are going). |
| constexpr auto | build_timeout after this many ms a path build times out |
| constexpr auto | latency_interval measure latency every this interval ms |
| constexpr auto | alive_timeout if a path is inactive for this amount of time it's dead |
| constexpr std::size_t | transit_hop_queue_size how big transit hop traffic queues are |
| constexpr auto | MIN_PATH_BUILD_INTERVAL |
| constexpr auto | PATH_BUILD_RATE |
| constexpr PathRole | ePathRoleAny capable of any role |
| constexpr PathRole | ePathRoleOutboundHS outbound hs traffic capable |
| constexpr PathRole | ePathRoleInboundHS inbound hs traffic capable |
| constexpr PathRole | ePathRoleExit exit traffic capable |
| constexpr PathRole | ePathRoleSVC service node capable |
| constexpr PathRole | ePathRoleDHT dht message capable |
Types Documentation
enum PathStatus
| Enumerator | Value | Description |
|---|---|---|
| ePathBuilding | ||
| ePathEstablished | ||
| ePathTimeout | ||
| ePathFailed | ||
| ePathIgnore | ||
| ePathExpired |
status of a path
using HopHandler_ptr
using llarp::path::HopHandler_ptr = typedef std::shared_ptr<IHopHandler>;
typedef TransitHop_ptr
typedef std::shared_ptr< TransitHop > llarp::path::TransitHop_ptr;
using Builder_ptr
using llarp::path::Builder_ptr = typedef std::shared_ptr<Builder>;
using PathRole
using llarp::path::PathRole = typedef int;
the role of this path can fulfill
typedef Path_ptr
typedef std::shared_ptr< Path > llarp::path::Path_ptr;
using PathSet_ptr
using llarp::path::PathSet_ptr = typedef std::shared_ptr<PathSet>;
Functions Documentation
function operator<
inline bool operator<(
const PathHopConfig & lhs,
const PathHopConfig & rhs
)
function operator==
inline bool operator==(
const TransitHopInfo & lhs,
const TransitHopInfo & rhs
)
function operator!=
inline bool operator!=(
const TransitHopInfo & lhs,
const TransitHopInfo & rhs
)
function operator<
inline bool operator<(
const TransitHopInfo & lhs,
const TransitHopInfo & rhs
)
Attributes Documentation
variable max_len
constexpr std::size_t max_len = 8;
maximum path length
variable default_len
constexpr std::size_t default_len = 4;
default path length
variable pad_size
constexpr std::size_t pad_size = 128;
pad messages to the nearest this many bytes
variable default_lifetime
constexpr std::chrono::milliseconds default_lifetime = 20min;
default path lifetime in ms
variable min_intro_lifetime
constexpr std::chrono::milliseconds min_intro_lifetime = default_lifetime / 2;
minimum into lifetime we will advertise
variable intro_spread_slices
constexpr auto intro_spread_slices = 4;
number of slices of path lifetime to spread intros out via
variable intro_path_spread
constexpr std::chrono::milliseconds intro_path_spread = default_lifetime / intro_spread_slices;
spacing frequency at which we try to build paths for introductions
variable intro_stale_threshold
constexpr std::chrono::milliseconds intro_stale_threshold =
default_lifetime - intro_path_spread;
how long away from expiration in millseconds do we consider an intro to become stale
variable min_intro_paths
constexpr std::size_t min_intro_paths = 4;
Minimum paths to keep around for intros; mainly used at startup (the spread, above, should be able to maintain more than this number of paths normally once things are going).
variable build_timeout
constexpr auto build_timeout = 10s;
after this many ms a path build times out
variable latency_interval
constexpr auto latency_interval = 5s;
measure latency every this interval ms
variable alive_timeout
constexpr auto alive_timeout = 10s;
if a path is inactive for this amount of time it's dead
variable transit_hop_queue_size
constexpr std::size_t transit_hop_queue_size = 256;
how big transit hop traffic queues are
variable MIN_PATH_BUILD_INTERVAL
static constexpr auto MIN_PATH_BUILD_INTERVAL = 500ms;
variable PATH_BUILD_RATE
static constexpr auto PATH_BUILD_RATE = 100ms;
variable ePathRoleAny
constexpr PathRole ePathRoleAny = 0;
capable of any role
variable ePathRoleOutboundHS
constexpr PathRole ePathRoleOutboundHS = (1 << 0);
outbound hs traffic capable
variable ePathRoleInboundHS
constexpr PathRole ePathRoleInboundHS = (1 << 1);
inbound hs traffic capable
variable ePathRoleExit
constexpr PathRole ePathRoleExit = (1 << 2);
exit traffic capable
variable ePathRoleSVC
constexpr PathRole ePathRoleSVC = (1 << 3);
service node capable
variable ePathRoleDHT
constexpr PathRole ePathRoleDHT = (1 << 4);
dht message capable
Updated on 2026-01-10 at 22:49:45 +0000