Files
rippled/peerfinder_2impl_2Tuning_8h_source.html
2022-02-08 03:25:25 +00:00

222 lines
32 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.17"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>rippled: Tuning.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">rippled
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.17 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="dir_df9c78dcf3f59a33b12284f95992a64b.html">ripple</a></li><li class="navelem"><a class="el" href="dir_44aff85a5b558cac9311bb222eb8fa78.html">peerfinder</a></li><li class="navelem"><a class="el" href="dir_01f812eedbcff88039c2ca147e9e73a6.html">impl</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="headertitle">
<div class="title">peerfinder/impl/Tuning.h</div> </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span>&#160;<span class="comment">//------------------------------------------------------------------------------</span></div>
<div class="line"><a name="l00002"></a><span class="lineno"> 2</span>&#160;<span class="comment">/*</span></div>
<div class="line"><a name="l00003"></a><span class="lineno"> 3</span>&#160;<span class="comment"> This file is part of rippled: https://github.com/ripple/rippled</span></div>
<div class="line"><a name="l00004"></a><span class="lineno"> 4</span>&#160;<span class="comment"> Copyright (c) 2012, 2013 Ripple Labs Inc.</span></div>
<div class="line"><a name="l00005"></a><span class="lineno"> 5</span>&#160;<span class="comment"></span> </div>
<div class="line"><a name="l00006"></a><span class="lineno"> 6</span>&#160;<span class="comment"> Permission to use, copy, modify, and/or distribute this software for any</span></div>
<div class="line"><a name="l00007"></a><span class="lineno"> 7</span>&#160;<span class="comment"> purpose with or without fee is hereby granted, provided that the above</span></div>
<div class="line"><a name="l00008"></a><span class="lineno"> 8</span>&#160;<span class="comment"> copyright notice and this permission notice appear in all copies.</span></div>
<div class="line"><a name="l00009"></a><span class="lineno"> 9</span>&#160;<span class="comment"></span> </div>
<div class="line"><a name="l00010"></a><span class="lineno"> 10</span>&#160;<span class="comment"> THE SOFTWARE IS PROVIDED &quot;AS IS&quot; AND THE AUTHOR DISCLAIMS ALL WARRANTIES</span></div>
<div class="line"><a name="l00011"></a><span class="lineno"> 11</span>&#160;<span class="comment"> WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF</span></div>
<div class="line"><a name="l00012"></a><span class="lineno"> 12</span>&#160;<span class="comment"> MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR</span></div>
<div class="line"><a name="l00013"></a><span class="lineno"> 13</span>&#160;<span class="comment"> ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES</span></div>
<div class="line"><a name="l00014"></a><span class="lineno"> 14</span>&#160;<span class="comment"> WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN</span></div>
<div class="line"><a name="l00015"></a><span class="lineno"> 15</span>&#160;<span class="comment"> ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF</span></div>
<div class="line"><a name="l00016"></a><span class="lineno"> 16</span>&#160;<span class="comment"> OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.</span></div>
<div class="line"><a name="l00017"></a><span class="lineno"> 17</span>&#160;<span class="comment">*/</span></div>
<div class="line"><a name="l00018"></a><span class="lineno"> 18</span>&#160;<span class="comment">//==============================================================================</span></div>
<div class="line"><a name="l00019"></a><span class="lineno"> 19</span>&#160; </div>
<div class="line"><a name="l00020"></a><span class="lineno"> 20</span>&#160;<span class="preprocessor">#ifndef RIPPLE_PEERFINDER_TUNING_H_INCLUDED</span></div>
<div class="line"><a name="l00021"></a><span class="lineno"> 21</span>&#160;<span class="preprocessor">#define RIPPLE_PEERFINDER_TUNING_H_INCLUDED</span></div>
<div class="line"><a name="l00022"></a><span class="lineno"> 22</span>&#160; </div>
<div class="line"><a name="l00023"></a><span class="lineno"> 23</span>&#160;<span class="preprocessor">#include &lt;<a class="codeRef" href="http://en.cppreference.com/w/cpp/header/array.html">array</a>&gt;</span></div>
<div class="line"><a name="l00024"></a><span class="lineno"> 24</span>&#160; </div>
<div class="line"><a name="l00025"></a><span class="lineno"> 25</span>&#160;<span class="keyword">namespace </span><a class="code" href="namespaceripple.html">ripple</a> {</div>
<div class="line"><a name="l00026"></a><span class="lineno"> 26</span>&#160;<span class="keyword">namespace </span>PeerFinder {</div>
<div class="line"><a name="l00027"></a><span class="lineno"> 27</span>&#160; </div>
<div class="line"><a name="l00030"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html"> 30</a></span>&#160;<span class="keyword">namespace </span>Tuning {</div>
<div class="line"><a name="l00031"></a><span class="lineno"> 31</span>&#160; </div>
<div class="line"><a name="l00032"></a><span class="lineno"> 32</span>&#160;<span class="keyword">enum</span> {</div>
<div class="line"><a name="l00033"></a><span class="lineno"> 33</span>&#160; <span class="comment">//---------------------------------------------------------</span></div>
<div class="line"><a name="l00034"></a><span class="lineno"> 34</span>&#160; <span class="comment">//</span></div>
<div class="line"><a name="l00035"></a><span class="lineno"> 35</span>&#160; <span class="comment">// Automatic Connection Policy</span></div>
<div class="line"><a name="l00036"></a><span class="lineno"> 36</span>&#160; <span class="comment">//</span></div>
<div class="line"><a name="l00037"></a><span class="lineno"> 37</span>&#160; <span class="comment">//---------------------------------------------------------</span></div>
<div class="line"><a name="l00038"></a><span class="lineno"> 38</span>&#160; </div>
<div class="line"><a name="l00040"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a55d806cee607bc4ee75497efb6b895f3"> 40</a></span>&#160; <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a55d806cee607bc4ee75497efb6b895f3">secondsPerConnect</a> = 10</div>
<div class="line"><a name="l00041"></a><span class="lineno"> 41</span>&#160; </div>
<div class="line"><a name="l00043"></a><span class="lineno"> 43</span>&#160; ,</div>
<div class="line"><a name="l00044"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a8a6872ddbb47d7d8ae0223377020d1d1"> 44</a></span>&#160; <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a8a6872ddbb47d7d8ae0223377020d1d1">maxConnectAttempts</a> = 20</div>
<div class="line"><a name="l00045"></a><span class="lineno"> 45</span>&#160; </div>
<div class="line"><a name="l00051"></a><span class="lineno"> 51</span>&#160; ,</div>
<div class="line"><a name="l00052"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a4bdda2a4de62bd1ac3594de895ba3b10"> 52</a></span>&#160; <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a4bdda2a4de62bd1ac3594de895ba3b10">outPercent</a> = 15</div>
<div class="line"><a name="l00053"></a><span class="lineno"> 53</span>&#160; </div>
<div class="line"><a name="l00058"></a><span class="lineno"> 58</span>&#160; ,</div>
<div class="line"><a name="l00059"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8adfb5a5032cadf474a7d73130e7bdfbab"> 59</a></span>&#160; <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8adfb5a5032cadf474a7d73130e7bdfbab">minOutCount</a> = 10</div>
<div class="line"><a name="l00060"></a><span class="lineno"> 60</span>&#160; </div>
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span>&#160; ,</div>
<div class="line"><a name="l00063"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8ae2613c88dfdb6971e3738f1f7ef8f295"> 63</a></span>&#160; <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8ae2613c88dfdb6971e3738f1f7ef8f295">defaultMaxPeers</a> = 21</div>
<div class="line"><a name="l00064"></a><span class="lineno"> 64</span>&#160; </div>
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span>&#160; ,</div>
<div class="line"><a name="l00070"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a212731207fffda9c87043e6970a33329"> 70</a></span>&#160; <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a212731207fffda9c87043e6970a33329">maxRedirects</a> = 30</div>
<div class="line"><a name="l00071"></a><span class="lineno"> 71</span>&#160;};</div>
<div class="line"><a name="l00072"></a><span class="lineno"> 72</span>&#160; </div>
<div class="line"><a name="l00073"></a><span class="lineno"> 73</span>&#160;<span class="comment">//------------------------------------------------------------------------------</span></div>
<div class="line"><a name="l00074"></a><span class="lineno"> 74</span>&#160;<span class="comment">//</span></div>
<div class="line"><a name="l00075"></a><span class="lineno"> 75</span>&#160;<span class="comment">// Fixed</span></div>
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>&#160;<span class="comment">//</span></div>
<div class="line"><a name="l00077"></a><span class="lineno"> 77</span>&#160;<span class="comment">//------------------------------------------------------------------------------</span></div>
<div class="line"><a name="l00078"></a><span class="lineno"> 78</span>&#160; </div>
<div class="line"><a name="l00079"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a4395e6f3599d47cada17f80fe10f479c"> 79</a></span>&#160;<span class="keyword">static</span> <a class="codeRef" href="http://en.cppreference.com/w/cpp/container/array.html">std::array&lt;int, 10&gt;</a> <span class="keyword">const</span> <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a4395e6f3599d47cada17f80fe10f479c">connectionBackoff</a>{</div>
<div class="line"><a name="l00080"></a><span class="lineno"> 80</span>&#160; {1, 1, 2, 3, 5, 8, 13, 21, 34, 55}};</div>
<div class="line"><a name="l00081"></a><span class="lineno"> 81</span>&#160; </div>
<div class="line"><a name="l00082"></a><span class="lineno"> 82</span>&#160;<span class="comment">//------------------------------------------------------------------------------</span></div>
<div class="line"><a name="l00083"></a><span class="lineno"> 83</span>&#160;<span class="comment">//</span></div>
<div class="line"><a name="l00084"></a><span class="lineno"> 84</span>&#160;<span class="comment">// Bootcache</span></div>
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span>&#160;<span class="comment">//</span></div>
<div class="line"><a name="l00086"></a><span class="lineno"> 86</span>&#160;<span class="comment">//------------------------------------------------------------------------------</span></div>
<div class="line"><a name="l00087"></a><span class="lineno"> 87</span>&#160; </div>
<div class="line"><a name="l00088"></a><span class="lineno"> 88</span>&#160;<span class="keyword">enum</span> {</div>
<div class="line"><a name="l00089"></a><span class="lineno"> 89</span>&#160; <span class="comment">// Threshold of cache entries above which we trim.</span></div>
<div class="line"><a name="l00090"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#aece7fa7a4fd22af031a6aef7ca474946aa5370251f3b67c6964070abba176411e"> 90</a></span>&#160; <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#aece7fa7a4fd22af031a6aef7ca474946aa5370251f3b67c6964070abba176411e">bootcacheSize</a> = 1000</div>
<div class="line"><a name="l00091"></a><span class="lineno"> 91</span>&#160; </div>
<div class="line"><a name="l00092"></a><span class="lineno"> 92</span>&#160; <span class="comment">// The percentage of addresses we prune when we trim the cache.</span></div>
<div class="line"><a name="l00093"></a><span class="lineno"> 93</span>&#160; ,</div>
<div class="line"><a name="l00094"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#aece7fa7a4fd22af031a6aef7ca474946a812b763d40e801379f710816646374fc"> 94</a></span>&#160; <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#aece7fa7a4fd22af031a6aef7ca474946a812b763d40e801379f710816646374fc">bootcachePrunePercent</a> = 10</div>
<div class="line"><a name="l00095"></a><span class="lineno"> 95</span>&#160;};</div>
<div class="line"><a name="l00096"></a><span class="lineno"> 96</span>&#160; </div>
<div class="line"><a name="l00097"></a><span class="lineno"> 97</span>&#160;<span class="comment">// The cool down wait between database updates</span></div>
<div class="line"><a name="l00098"></a><span class="lineno"> 98</span>&#160;<span class="comment">// Ideally this should be larger than the time it takes a full</span></div>
<div class="line"><a name="l00099"></a><span class="lineno"> 99</span>&#160;<span class="comment">// peer to send us a set of addresses and then disconnect.</span></div>
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span>&#160;<span class="comment">//</span></div>
<div class="line"><a name="l00101"></a><span class="lineno"> 101</span>&#160;<span class="keyword">static</span> <a class="codeRef" href="http://en.cppreference.com/w/cpp/chrono/duration.html">std::chrono::seconds</a> <span class="keyword">const</span> <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#ada552bb06c6958020a24fc1341dba2f7">bootcacheCooldownTime</a>(60);</div>
<div class="line"><a name="l00102"></a><span class="lineno"> 102</span>&#160; </div>
<div class="line"><a name="l00103"></a><span class="lineno"> 103</span>&#160;<span class="comment">//------------------------------------------------------------------------------</span></div>
<div class="line"><a name="l00104"></a><span class="lineno"> 104</span>&#160;<span class="comment">//</span></div>
<div class="line"><a name="l00105"></a><span class="lineno"> 105</span>&#160;<span class="comment">// Livecache</span></div>
<div class="line"><a name="l00106"></a><span class="lineno"> 106</span>&#160;<span class="comment">//</span></div>
<div class="line"><a name="l00107"></a><span class="lineno"> 107</span>&#160;<span class="comment">//------------------------------------------------------------------------------</span></div>
<div class="line"><a name="l00108"></a><span class="lineno"> 108</span>&#160; </div>
<div class="line"><a name="l00109"></a><span class="lineno"> 109</span>&#160;<span class="comment">// Drop incoming messages with hops greater than this number</span></div>
<div class="line"><a name="l00110"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a29079dc81726f6923bc08a141607737c"> 110</a></span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a> constexpr <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a29079dc81726f6923bc08a141607737c">maxHops</a> = 6;</div>
<div class="line"><a name="l00111"></a><span class="lineno"> 111</span>&#160; </div>
<div class="line"><a name="l00112"></a><span class="lineno"> 112</span>&#160;<span class="comment">// How many Endpoint to send in each mtENDPOINTS</span></div>
<div class="line"><a name="l00113"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a6e2730b7382191536c83f3a35e58626b"> 113</a></span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a> constexpr <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a6e2730b7382191536c83f3a35e58626b">numberOfEndpoints</a> = 2 * <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a29079dc81726f6923bc08a141607737c">maxHops</a>;</div>
<div class="line"><a name="l00114"></a><span class="lineno"> 114</span>&#160; </div>
<div class="line"><a name="l00115"></a><span class="lineno"> 115</span>&#160;<span class="comment">// The most Endpoint we will accept in mtENDPOINTS</span></div>
<div class="line"><a name="l00116"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a653e96b3052c8ce2d7adae974d9f973a"> 116</a></span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a> constexpr <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a653e96b3052c8ce2d7adae974d9f973a">numberOfEndpointsMax</a> =</div>
<div class="line"><a name="l00117"></a><span class="lineno"> 117</span>&#160; std::max&lt;decltype(numberOfEndpoints)&gt;(<a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a6e2730b7382191536c83f3a35e58626b">numberOfEndpoints</a> * 2, 64);</div>
<div class="line"><a name="l00118"></a><span class="lineno"> 118</span>&#160; </div>
<div class="line"><a name="l00119"></a><span class="lineno"> 119</span>&#160;<span class="comment">// Number of addresses we provide when redirecting.</span></div>
<div class="line"><a name="l00120"></a><span class="lineno"><a class="line" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#abc57d92751e39193c52099debc243750"> 120</a></span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a> constexpr <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#abc57d92751e39193c52099debc243750">redirectEndpointCount</a> = 10;</div>
<div class="line"><a name="l00121"></a><span class="lineno"> 121</span>&#160; </div>
<div class="line"><a name="l00122"></a><span class="lineno"> 122</span>&#160;<span class="comment">// How often we send or accept mtENDPOINTS messages per peer</span></div>
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span>&#160;<span class="comment">// (we use a prime number of purpose)</span></div>
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/chrono/duration.html">std::chrono::seconds</a> constexpr <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a7269657491cfef42d7e1480798153163">secondsPerMessage</a>(151);</div>
<div class="line"><a name="l00125"></a><span class="lineno"> 125</span>&#160; </div>
<div class="line"><a name="l00126"></a><span class="lineno"> 126</span>&#160;<span class="comment">// How long an Endpoint will stay in the cache</span></div>
<div class="line"><a name="l00127"></a><span class="lineno"> 127</span>&#160;<span class="comment">// This should be a small multiple of the broadcast frequency</span></div>
<div class="line"><a name="l00128"></a><span class="lineno"> 128</span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/chrono/duration.html">std::chrono::seconds</a> constexpr <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a4505f8120be51df363c12837213f2a36">liveCacheSecondsToLive</a>(30);</div>
<div class="line"><a name="l00129"></a><span class="lineno"> 129</span>&#160; </div>
<div class="line"><a name="l00130"></a><span class="lineno"> 130</span>&#160;<span class="comment">// How much time to wait before trying an outgoing address again.</span></div>
<div class="line"><a name="l00131"></a><span class="lineno"> 131</span>&#160;<span class="comment">// Note that we ignore the port for purposes of comparison.</span></div>
<div class="line"><a name="l00132"></a><span class="lineno"> 132</span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/chrono/duration.html">std::chrono::seconds</a> constexpr <a class="code" href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a546460b77d56a4f01c1ab2f54e82103a">recentAttemptDuration</a>(60);</div>
<div class="line"><a name="l00133"></a><span class="lineno"> 133</span>&#160; </div>
<div class="line"><a name="l00134"></a><span class="lineno"> 134</span>&#160;} <span class="comment">// namespace Tuning</span></div>
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span>&#160;<span class="comment"></span>} <span class="comment">// namespace PeerFinder</span></div>
<div class="line"><a name="l00138"></a><span class="lineno"> 138</span>&#160;} <span class="comment">// namespace ripple</span></div>
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span>&#160; </div>
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span>&#160;<span class="preprocessor">#endif</span></div>
</div><!-- fragment --></div><!-- contents -->
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_abc57d92751e39193c52099debc243750"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#abc57d92751e39193c52099debc243750">ripple::PeerFinder::Tuning::redirectEndpointCount</a></div><div class="ttdeci">constexpr std::uint32_t redirectEndpointCount</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00120">peerfinder/impl/Tuning.h:120</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a2ad6eef9f47f6d98246d0a51059b5bb8ae2613c88dfdb6971e3738f1f7ef8f295"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8ae2613c88dfdb6971e3738f1f7ef8f295">ripple::PeerFinder::Tuning::defaultMaxPeers</a></div><div class="ttdeci">@ defaultMaxPeers</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00063">peerfinder/impl/Tuning.h:63</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_ada552bb06c6958020a24fc1341dba2f7"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#ada552bb06c6958020a24fc1341dba2f7">ripple::PeerFinder::Tuning::bootcacheCooldownTime</a></div><div class="ttdeci">static const std::chrono::seconds bootcacheCooldownTime(60)</div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a2ad6eef9f47f6d98246d0a51059b5bb8a212731207fffda9c87043e6970a33329"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a212731207fffda9c87043e6970a33329">ripple::PeerFinder::Tuning::maxRedirects</a></div><div class="ttdeci">@ maxRedirects</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00070">peerfinder/impl/Tuning.h:70</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_aece7fa7a4fd22af031a6aef7ca474946aa5370251f3b67c6964070abba176411e"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#aece7fa7a4fd22af031a6aef7ca474946aa5370251f3b67c6964070abba176411e">ripple::PeerFinder::Tuning::bootcacheSize</a></div><div class="ttdeci">@ bootcacheSize</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00090">peerfinder/impl/Tuning.h:90</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a7269657491cfef42d7e1480798153163"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a7269657491cfef42d7e1480798153163">ripple::PeerFinder::Tuning::secondsPerMessage</a></div><div class="ttdeci">constexpr std::chrono::seconds secondsPerMessage(151)</div></div>
<div class="ttc" id="aduration_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/chrono/duration.html">std::chrono::seconds</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a653e96b3052c8ce2d7adae974d9f973a"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a653e96b3052c8ce2d7adae974d9f973a">ripple::PeerFinder::Tuning::numberOfEndpointsMax</a></div><div class="ttdeci">constexpr std::uint32_t numberOfEndpointsMax</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00116">peerfinder/impl/Tuning.h:116</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a4505f8120be51df363c12837213f2a36"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a4505f8120be51df363c12837213f2a36">ripple::PeerFinder::Tuning::liveCacheSecondsToLive</a></div><div class="ttdeci">constexpr std::chrono::seconds liveCacheSecondsToLive(30)</div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a2ad6eef9f47f6d98246d0a51059b5bb8a8a6872ddbb47d7d8ae0223377020d1d1"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a8a6872ddbb47d7d8ae0223377020d1d1">ripple::PeerFinder::Tuning::maxConnectAttempts</a></div><div class="ttdeci">@ maxConnectAttempts</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00044">peerfinder/impl/Tuning.h:44</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a4395e6f3599d47cada17f80fe10f479c"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a4395e6f3599d47cada17f80fe10f479c">ripple::PeerFinder::Tuning::connectionBackoff</a></div><div class="ttdeci">static const std::array&lt; int, 10 &gt; connectionBackoff</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00079">peerfinder/impl/Tuning.h:79</a></div></div>
<div class="ttc" id="aarray_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/header/array.html">array</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a2ad6eef9f47f6d98246d0a51059b5bb8a4bdda2a4de62bd1ac3594de895ba3b10"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a4bdda2a4de62bd1ac3594de895ba3b10">ripple::PeerFinder::Tuning::outPercent</a></div><div class="ttdeci">@ outPercent</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00052">peerfinder/impl/Tuning.h:52</a></div></div>
<div class="ttc" id="ainteger_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a546460b77d56a4f01c1ab2f54e82103a"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a546460b77d56a4f01c1ab2f54e82103a">ripple::PeerFinder::Tuning::recentAttemptDuration</a></div><div class="ttdeci">constexpr std::chrono::seconds recentAttemptDuration(60)</div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a2ad6eef9f47f6d98246d0a51059b5bb8adfb5a5032cadf474a7d73130e7bdfbab"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8adfb5a5032cadf474a7d73130e7bdfbab">ripple::PeerFinder::Tuning::minOutCount</a></div><div class="ttdeci">@ minOutCount</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00059">peerfinder/impl/Tuning.h:59</a></div></div>
<div class="ttc" id="anamespaceripple_html"><div class="ttname"><a href="namespaceripple.html">ripple</a></div><div class="ttdoc">Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.</div><div class="ttdef"><b>Definition:</b> <a href="RCLCensorshipDetector_8h_source.html#l00029">RCLCensorshipDetector.h:29</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_aece7fa7a4fd22af031a6aef7ca474946a812b763d40e801379f710816646374fc"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#aece7fa7a4fd22af031a6aef7ca474946a812b763d40e801379f710816646374fc">ripple::PeerFinder::Tuning::bootcachePrunePercent</a></div><div class="ttdeci">@ bootcachePrunePercent</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00094">peerfinder/impl/Tuning.h:94</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a2ad6eef9f47f6d98246d0a51059b5bb8a55d806cee607bc4ee75497efb6b895f3"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a2ad6eef9f47f6d98246d0a51059b5bb8a55d806cee607bc4ee75497efb6b895f3">ripple::PeerFinder::Tuning::secondsPerConnect</a></div><div class="ttdeci">@ secondsPerConnect</div><div class="ttdoc">Time to wait between making batches of connection attempts.</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00040">peerfinder/impl/Tuning.h:40</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a29079dc81726f6923bc08a141607737c"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a29079dc81726f6923bc08a141607737c">ripple::PeerFinder::Tuning::maxHops</a></div><div class="ttdeci">constexpr std::uint32_t maxHops</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00110">peerfinder/impl/Tuning.h:110</a></div></div>
<div class="ttc" id="anamespaceripple_1_1PeerFinder_1_1Tuning_html_a6e2730b7382191536c83f3a35e58626b"><div class="ttname"><a href="namespaceripple_1_1PeerFinder_1_1Tuning.html#a6e2730b7382191536c83f3a35e58626b">ripple::PeerFinder::Tuning::numberOfEndpoints</a></div><div class="ttdeci">constexpr std::uint32_t numberOfEndpoints</div><div class="ttdef"><b>Definition:</b> <a href="peerfinder_2impl_2Tuning_8h_source.html#l00113">peerfinder/impl/Tuning.h:113</a></div></div>
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.17
</small></address>
</body>
</html>