reduce path intro spread slices from 5 to 4.

parameterize path intro spread slices.
This commit is contained in:
Jeff Becker 2021-06-02 15:24:44 -04:00
parent 08d62e32c0
commit 5849176f04
No known key found for this signature in database
GPG Key ID: F357B3B42F6F9B05
1 changed files with 3 additions and 1 deletions

View File

@ -20,8 +20,10 @@ namespace llarp
constexpr std::chrono::milliseconds default_lifetime = 20min;
/// minimum into lifetime we will advertise
constexpr std::chrono::milliseconds min_intro_lifetime = default_lifetime / 2;
/// number of slices of path lifetime to spread intros out via
constexpr auto intro_spread_slices = 4;
/// spacing frequency at which we try to build paths for introductions
constexpr std::chrono::milliseconds intro_path_spread = default_lifetime / 5;
constexpr std::chrono::milliseconds intro_path_spread = default_lifetime / intro_spread_slices;
/// 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).