1#include <xrpld/app/misc/setup_HashRouter.h>
2#include <xrpld/core/Config.h>
4#include <xrpl/basics/BasicConfig.h>
14 auto const& section = config.
section(
"hashrouter");
18 if (
set(tmp,
"hold_time", section))
21 Throw<std::runtime_error>(
22 "HashRouter hold time must be at least 12 seconds (the "
23 "approximate validation time for three ledgers).");
26 if (
set(tmp,
"relay_time", section))
29 Throw<std::runtime_error>(
30 "HashRouter relay time must be at least 8 seconds (the "
31 "approximate validation time for two ledgers).");
36 Throw<std::runtime_error>(
"HashRouter relay time must be less than or equal to hold time");
Section & section(std::string const &name)
Returns the section with the given name.
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
HashRouter::Setup setup_HashRouter(Config const &config)
Create HashRouter setup from configuration.
Structure used to customize HashRouter behavior.
seconds holdTime
Expiration time for a hash entry.
seconds relayTime
Amount of time required before a relayed item will be relayed again.