mirror of
https://github.com/oxen-io/lokinet
synced 2023-12-14 06:53:00 +01:00
De-static constants
We don't need separate copies of these per compilation unit.
This commit is contained in:
parent
823c17206f
commit
58fe7ac801
|
@ -18,24 +18,24 @@ namespace llarp
|
|||
/// pad messages to the nearest this many bytes
|
||||
constexpr std::size_t pad_size = 128;
|
||||
/// default path lifetime in ms
|
||||
static constexpr std::chrono::milliseconds default_lifetime = 20min;
|
||||
constexpr std::chrono::milliseconds default_lifetime = 20min;
|
||||
/// minimum into lifetime we will advertise
|
||||
static constexpr std::chrono::milliseconds min_intro_lifetime =
|
||||
constexpr std::chrono::milliseconds min_intro_lifetime =
|
||||
default_lifetime / 2;
|
||||
/// spacing frequency at which we try to build paths for introductions
|
||||
static constexpr std::chrono::milliseconds intro_path_spread =
|
||||
constexpr std::chrono::milliseconds intro_path_spread =
|
||||
default_lifetime / 5;
|
||||
/// 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 std::size_t min_intro_paths = 4;
|
||||
/// after this many ms a path build times out
|
||||
static constexpr auto build_timeout = 30s;
|
||||
constexpr auto build_timeout = 30s;
|
||||
|
||||
/// measure latency every this interval ms
|
||||
static constexpr auto latency_interval = 5s;
|
||||
constexpr auto latency_interval = 5s;
|
||||
/// if a path is inactive for this amount of time it's dead
|
||||
static constexpr auto alive_timeout = 30s;
|
||||
constexpr auto alive_timeout = 30s;
|
||||
} // namespace path
|
||||
} // namespace llarp
|
||||
|
||||
|
|
Loading…
Reference in a new issue