This commit is contained in:
nbougalis
2020-12-21 13:57:13 +00:00
parent 00ae94e785
commit c55b377da7
2394 changed files with 44923 additions and 47046 deletions

View File

@@ -105,306 +105,232 @@ $(function() {
<div class="line"><a name="l00034"></a><span class="lineno"> 34</span>&#160; <a class="code" href="classripple_1_1Section.html">Section</a> <span class="keyword">const</span>&amp; config,</div>
<div class="line"><a name="l00035"></a><span class="lineno"> 35</span>&#160; <a class="code" href="classbeast_1_1Journal.html">beast::Journal</a> j)</div>
<div class="line"><a name="l00036"></a><span class="lineno"> 36</span>&#160; : <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotating.html">DatabaseRotating</a>(name, parent, scheduler, readThreads, config, j)</div>
<div class="line"><a name="l00037"></a><span class="lineno"> 37</span>&#160; , pCache_(<a class="code" href="namespacestd.html">std</a>::make_shared&lt;<a class="code" href="classripple_1_1TaggedCache.html">TaggedCache</a>&lt;<a class="code" href="classripple_1_1base__uint.html">uint256</a>, <a class="code" href="classripple_1_1NodeObject.html">NodeObject</a>&gt;&gt;(</div>
<div class="line"><a name="l00038"></a><span class="lineno"> 38</span>&#160; name,</div>
<div class="line"><a name="l00039"></a><span class="lineno"> 39</span>&#160; <a class="code" href="namespaceripple_1_1NodeStore.html#ab026118fd22b5e7db14b5dea6938aaa8a82fcd9983079b023efaf136078d3d2d3">cacheTargetSize</a>,</div>
<div class="line"><a name="l00040"></a><span class="lineno"> 40</span>&#160; <a class="code" href="namespaceripple_1_1NodeStore.html#a41cef3aa8ed33b8fa1b438ed7b6d1287">cacheTargetAge</a>,</div>
<div class="line"><a name="l00041"></a><span class="lineno"> 41</span>&#160; <a class="code" href="namespaceripple.html#ac70521ab6e1277870a9e400e7a08e937">stopwatch</a>(),</div>
<div class="line"><a name="l00042"></a><span class="lineno"> 42</span>&#160; j))</div>
<div class="line"><a name="l00043"></a><span class="lineno"> 43</span>&#160; , nCache_(<a class="code" href="namespacestd.html">std</a>::make_shared&lt;<a class="code" href="classripple_1_1KeyCache.html">KeyCache</a>&lt;<a class="code" href="classripple_1_1base__uint.html">uint256</a>&gt;&gt;(</div>
<div class="line"><a name="l00044"></a><span class="lineno"> 44</span>&#160; name,</div>
<div class="line"><a name="l00045"></a><span class="lineno"> 45</span>&#160; <a class="code" href="namespaceripple.html#ac70521ab6e1277870a9e400e7a08e937">stopwatch</a>(),</div>
<div class="line"><a name="l00046"></a><span class="lineno"> 46</span>&#160; <a class="code" href="namespaceripple_1_1NodeStore.html#ab026118fd22b5e7db14b5dea6938aaa8a82fcd9983079b023efaf136078d3d2d3">cacheTargetSize</a>,</div>
<div class="line"><a name="l00047"></a><span class="lineno"> 47</span>&#160; <a class="code" href="namespaceripple_1_1NodeStore.html#a41cef3aa8ed33b8fa1b438ed7b6d1287">cacheTargetAge</a>))</div>
<div class="line"><a name="l00048"></a><span class="lineno"> 48</span>&#160; , writableBackend_(<a class="code" href="namespacestd.html">std</a>::move(writableBackend))</div>
<div class="line"><a name="l00049"></a><span class="lineno"> 49</span>&#160; , archiveBackend_(<a class="code" href="namespacestd.html">std</a>::move(archiveBackend))</div>
<div class="line"><a name="l00050"></a><span class="lineno"> 50</span>&#160;{</div>
<div class="line"><a name="l00051"></a><span class="lineno"> 51</span>&#160; <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>)</div>
<div class="line"><a name="l00052"></a><span class="lineno"> 52</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#a730a87cf8b617a8afb30e2531ede0f81">fdRequired_</a> += <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>-&gt;fdRequired();</div>
<div class="line"><a name="l00053"></a><span class="lineno"> 53</span>&#160; <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>)</div>
<div class="line"><a name="l00054"></a><span class="lineno"> 54</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#a730a87cf8b617a8afb30e2531ede0f81">fdRequired_</a> += <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>-&gt;fdRequired();</div>
<div class="line"><a name="l00055"></a><span class="lineno"> 55</span>&#160; <a class="code" href="classripple_1_1Stoppable.html#adea135697761febf430a8628814c7902">setParent</a>(parent);</div>
<div class="line"><a name="l00056"></a><span class="lineno"> 56</span>&#160;}</div>
<div class="line"><a name="l00057"></a><span class="lineno"> 57</span>&#160; </div>
<div class="line"><a name="l00058"></a><span class="lineno"> 58</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00059"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a76f256f68048bc81a0d034f7226387b8"> 59</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a76f256f68048bc81a0d034f7226387b8">DatabaseRotatingImp::rotateWithLock</a>(</div>
<div class="line"><a name="l00060"></a><span class="lineno"> 60</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/functional/function.html">std::function</a>&lt;<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/unique_ptr.html">std::unique_ptr&lt;NodeStore::Backend&gt;</a>(</div>
<div class="line"><a name="l00061"></a><span class="lineno"> 61</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span>&amp; writableBackendName)&gt; <span class="keyword">const</span>&amp; f)</div>
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span>&#160;{</div>
<div class="line"><a name="l00037"></a><span class="lineno"> 37</span>&#160; , writableBackend_(<a class="code" href="namespacestd.html">std</a>::move(writableBackend))</div>
<div class="line"><a name="l00038"></a><span class="lineno"> 38</span>&#160; , archiveBackend_(<a class="code" href="namespacestd.html">std</a>::move(archiveBackend))</div>
<div class="line"><a name="l00039"></a><span class="lineno"> 39</span>&#160;{</div>
<div class="line"><a name="l00040"></a><span class="lineno"> 40</span>&#160; <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>)</div>
<div class="line"><a name="l00041"></a><span class="lineno"> 41</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#a730a87cf8b617a8afb30e2531ede0f81">fdRequired_</a> += <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>-&gt;fdRequired();</div>
<div class="line"><a name="l00042"></a><span class="lineno"> 42</span>&#160; <span class="keywordflow">if</span> (<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>)</div>
<div class="line"><a name="l00043"></a><span class="lineno"> 43</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#a730a87cf8b617a8afb30e2531ede0f81">fdRequired_</a> += <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>-&gt;fdRequired();</div>
<div class="line"><a name="l00044"></a><span class="lineno"> 44</span>&#160; <a class="code" href="classripple_1_1Stoppable.html#adea135697761febf430a8628814c7902">setParent</a>(parent);</div>
<div class="line"><a name="l00045"></a><span class="lineno"> 45</span>&#160;}</div>
<div class="line"><a name="l00046"></a><span class="lineno"> 46</span>&#160; </div>
<div class="line"><a name="l00047"></a><span class="lineno"> 47</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00048"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a76f256f68048bc81a0d034f7226387b8"> 48</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a76f256f68048bc81a0d034f7226387b8">DatabaseRotatingImp::rotateWithLock</a>(</div>
<div class="line"><a name="l00049"></a><span class="lineno"> 49</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/functional/function.html">std::function</a>&lt;<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/unique_ptr.html">std::unique_ptr&lt;NodeStore::Backend&gt;</a>(</div>
<div class="line"><a name="l00050"></a><span class="lineno"> 50</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a> <span class="keyword">const</span>&amp; writableBackendName)&gt; <span class="keyword">const</span>&amp; f)</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"> 52</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00053"></a><span class="lineno"> 53</span>&#160; </div>
<div class="line"><a name="l00054"></a><span class="lineno"> 54</span>&#160; <span class="keyword">auto</span> newBackend = f(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>-&gt;getName());</div>
<div class="line"><a name="l00055"></a><span class="lineno"> 55</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>-&gt;setDeletePath();</div>
<div class="line"><a name="l00056"></a><span class="lineno"> 56</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a> = std::move(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>);</div>
<div class="line"><a name="l00057"></a><span class="lineno"> 57</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a> = std::move(newBackend);</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"> 59</span>&#160; </div>
<div class="line"><a name="l00060"></a><span class="lineno"> 60</span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a></div>
<div class="line"><a name="l00061"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a9c3f2d7e8b7e4cca14afe2177c1466b3"> 61</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a9c3f2d7e8b7e4cca14afe2177c1466b3">DatabaseRotatingImp::getName</a>()<span class="keyword"> const</span></div>
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span>&#160;<span class="keyword"></span>{</div>
<div class="line"><a name="l00063"></a><span class="lineno"> 63</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00064"></a><span class="lineno"> 64</span>&#160; </div>
<div class="line"><a name="l00065"></a><span class="lineno"> 65</span>&#160; <span class="keyword">auto</span> newBackend = f(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>-&gt;getName());</div>
<div class="line"><a name="l00066"></a><span class="lineno"> 66</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>-&gt;setDeletePath();</div>
<div class="line"><a name="l00067"></a><span class="lineno"> 67</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a> = std::move(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>);</div>
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a> = std::move(newBackend);</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"> 70</span>&#160; </div>
<div class="line"><a name="l00071"></a><span class="lineno"> 71</span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a></div>
<div class="line"><a name="l00072"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a9c3f2d7e8b7e4cca14afe2177c1466b3"> 72</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a9c3f2d7e8b7e4cca14afe2177c1466b3">DatabaseRotatingImp::getName</a>()<span class="keyword"> const</span></div>
<div class="line"><a name="l00073"></a><span class="lineno"> 73</span>&#160;<span class="keyword"></span>{</div>
<div class="line"><a name="l00074"></a><span class="lineno"> 74</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00075"></a><span class="lineno"> 75</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>-&gt;getName();</div>
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>&#160;}</div>
<div class="line"><a name="l00077"></a><span class="lineno"> 77</span>&#160; </div>
<div class="line"><a name="l00078"></a><span class="lineno"> 78</span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::int32_t</a></div>
<div class="line"><a name="l00079"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a3b006f7535475fd276bc30b77a1b4673"> 79</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a3b006f7535475fd276bc30b77a1b4673">DatabaseRotatingImp::getWriteLoad</a>()<span class="keyword"> const</span></div>
<div class="line"><a name="l00080"></a><span class="lineno"> 80</span>&#160;<span class="keyword"></span>{</div>
<div class="line"><a name="l00081"></a><span class="lineno"> 81</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00082"></a><span class="lineno"> 82</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>-&gt;getWriteLoad();</div>
<div class="line"><a name="l00064"></a><span class="lineno"> 64</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>-&gt;getName();</div>
<div class="line"><a name="l00065"></a><span class="lineno"> 65</span>&#160;}</div>
<div class="line"><a name="l00066"></a><span class="lineno"> 66</span>&#160; </div>
<div class="line"><a name="l00067"></a><span class="lineno"> 67</span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::int32_t</a></div>
<div class="line"><a name="l00068"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a3b006f7535475fd276bc30b77a1b4673"> 68</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a3b006f7535475fd276bc30b77a1b4673">DatabaseRotatingImp::getWriteLoad</a>()<span class="keyword"> const</span></div>
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span>&#160;<span class="keyword"></span>{</div>
<div class="line"><a name="l00070"></a><span class="lineno"> 70</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00071"></a><span class="lineno"> 71</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>-&gt;getWriteLoad();</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; </div>
<div class="line"><a name="l00074"></a><span class="lineno"> 74</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00075"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ae018381e1b62ed9c61ef8a82d1b3db47"> 75</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ae018381e1b62ed9c61ef8a82d1b3db47">DatabaseRotatingImp::import</a>(<a class="code" href="classripple_1_1NodeStore_1_1Database.html">Database</a>&amp; source)</div>
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>&#160;{</div>
<div class="line"><a name="l00077"></a><span class="lineno"> 77</span>&#160; <span class="keyword">auto</span> <span class="keyword">const</span> backend = [&amp;] {</div>
<div class="line"><a name="l00078"></a><span class="lineno"> 78</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00079"></a><span class="lineno"> 79</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>;</div>
<div class="line"><a name="l00080"></a><span class="lineno"> 80</span>&#160; }();</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; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#af885d9fe877259a258481f0df20697cd">importInternal</a>(*backend, source);</div>
<div class="line"><a name="l00083"></a><span class="lineno"> 83</span>&#160;}</div>
<div class="line"><a name="l00084"></a><span class="lineno"> 84</span>&#160; </div>
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00086"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ae018381e1b62ed9c61ef8a82d1b3db47"> 86</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ae018381e1b62ed9c61ef8a82d1b3db47">DatabaseRotatingImp::import</a>(<a class="code" href="classripple_1_1NodeStore_1_1Database.html">Database</a>&amp; source)</div>
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span>&#160;<span class="keywordtype">bool</span></div>
<div class="line"><a name="l00086"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a55502de7f83a364526263b38bc1fe709"> 86</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a55502de7f83a364526263b38bc1fe709">DatabaseRotatingImp::storeLedger</a>(<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;Ledger const&gt;</a> <span class="keyword">const</span>&amp; srcLedger)</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">auto</span> <span class="keyword">const</span> backend = [&amp;] {</div>
<div class="line"><a name="l00089"></a><span class="lineno"> 89</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00090"></a><span class="lineno"> 90</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>;</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; </div>
<div class="line"><a name="l00093"></a><span class="lineno"> 93</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#af885d9fe877259a258481f0df20697cd">importInternal</a>(*backend, source);</div>
<div class="line"><a name="l00093"></a><span class="lineno"> 93</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1Database.html#aad7aa12d0cc01006120761d23312d428">Database::storeLedger</a>(*srcLedger, backend);</div>
<div class="line"><a name="l00094"></a><span class="lineno"> 94</span>&#160;}</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;<span class="keywordtype">bool</span></div>
<div class="line"><a name="l00097"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a55502de7f83a364526263b38bc1fe709"> 97</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a55502de7f83a364526263b38bc1fe709">DatabaseRotatingImp::storeLedger</a>(<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;Ledger const&gt;</a> <span class="keyword">const</span>&amp; srcLedger)</div>
<div class="line"><a name="l00098"></a><span class="lineno"> 98</span>&#160;{</div>
<div class="line"><a name="l00099"></a><span class="lineno"> 99</span>&#160; <span class="keyword">auto</span> <span class="keyword">const</span> backend = [&amp;] {</div>
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00101"></a><span class="lineno"> 101</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>;</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; </div>
<div class="line"><a name="l00104"></a><span class="lineno"> 104</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1Database.html#aad7aa12d0cc01006120761d23312d428">Database::storeLedger</a>(*srcLedger, backend, <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">pCache_</a>, <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">nCache_</a>);</div>
<div class="line"><a name="l00105"></a><span class="lineno"> 105</span>&#160;}</div>
<div class="line"><a name="l00106"></a><span class="lineno"> 106</span>&#160; </div>
<div class="line"><a name="l00107"></a><span class="lineno"> 107</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00108"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a7992d0dd009c5b855c331c73872c946d"> 108</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a7992d0dd009c5b855c331c73872c946d">DatabaseRotatingImp::store</a>(</div>
<div class="line"><a name="l00109"></a><span class="lineno"> 109</span>&#160; <a class="code" href="namespaceripple.html#a57d7e7b27df7e719fdf5569f96be60a3">NodeObjectType</a> type,</div>
<div class="line"><a name="l00110"></a><span class="lineno"> 110</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/container/vector.html">Blob</a>&amp;&amp; data,</div>
<div class="line"><a name="l00111"></a><span class="lineno"> 111</span>&#160; <a class="code" href="classripple_1_1base__uint.html">uint256</a> <span class="keyword">const</span>&amp; hash,</div>
<div class="line"><a name="l00112"></a><span class="lineno"> 112</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a>)</div>
<div class="line"><a name="l00113"></a><span class="lineno"> 113</span>&#160;{</div>
<div class="line"><a name="l00114"></a><span class="lineno"> 114</span>&#160; <span class="keyword">auto</span> nObj = <a class="code" href="classripple_1_1NodeObject.html#a841bb9bba547efbd89b240fa9c1cf146">NodeObject::createObject</a>(type, std::move(data), hash);</div>
<div class="line"><a name="l00115"></a><span class="lineno"> 115</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">pCache_</a>-&gt;canonicalize_replace_cache(hash, nObj);</div>
<div class="line"><a name="l00116"></a><span class="lineno"> 116</span>&#160; </div>
<div class="line"><a name="l00117"></a><span class="lineno"> 117</span>&#160; <span class="keyword">auto</span> <span class="keyword">const</span> backend = [&amp;] {</div>
<div class="line"><a name="l00118"></a><span class="lineno"> 118</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00119"></a><span class="lineno"> 119</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>;</div>
<div class="line"><a name="l00120"></a><span class="lineno"> 120</span>&#160; }();</div>
<div class="line"><a name="l00121"></a><span class="lineno"> 121</span>&#160; backend-&gt;store(nObj);</div>
<div class="line"><a name="l00122"></a><span class="lineno"> 122</span>&#160; </div>
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">nCache_</a>-&gt;erase(hash);</div>
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#a090e39b8c6733b0dc4553f9e8e705605">storeStats</a>(1, nObj-&gt;getData().size());</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; </div>
<div class="line"><a name="l00127"></a><span class="lineno"> 127</span>&#160;<span class="keywordtype">bool</span></div>
<div class="line"><a name="l00128"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a01b2627edcc41e0ea4cd5ac6b0518494"> 128</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a01b2627edcc41e0ea4cd5ac6b0518494">DatabaseRotatingImp::asyncFetch</a>(</div>
<div class="line"><a name="l00129"></a><span class="lineno"> 129</span>&#160; <a class="code" href="classripple_1_1base__uint.html">uint256</a> <span class="keyword">const</span>&amp; hash,</div>
<div class="line"><a name="l00130"></a><span class="lineno"> 130</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a> ledgerSeq,</div>
<div class="line"><a name="l00131"></a><span class="lineno"> 131</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;NodeObject&gt;</a>&amp; nodeObject)</div>
<div class="line"><a name="l00132"></a><span class="lineno"> 132</span>&#160;{</div>
<div class="line"><a name="l00133"></a><span class="lineno"> 133</span>&#160; <span class="comment">// See if the object is in cache</span></div>
<div class="line"><a name="l00134"></a><span class="lineno"> 134</span>&#160; nodeObject = <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">pCache_</a>-&gt;fetch(hash);</div>
<div class="line"><a name="l00135"></a><span class="lineno"> 135</span>&#160; <span class="keywordflow">if</span> (nodeObject || <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">nCache_</a>-&gt;touch_if_exists(hash))</div>
<div class="line"><a name="l00136"></a><span class="lineno"> 136</span>&#160; <span class="keywordflow">return</span> <span class="keyword">true</span>;</div>
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span>&#160; </div>
<div class="line"><a name="l00138"></a><span class="lineno"> 138</span>&#160; <span class="comment">// Otherwise post a read</span></div>
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#abff61416b213b5ab28e482a61a9c80f8">Database::asyncFetch</a>(hash, ledgerSeq);</div>
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span>&#160; <span class="keywordflow">return</span> <span class="keyword">false</span>;</div>
<div class="line"><a name="l00141"></a><span class="lineno"> 141</span>&#160;}</div>
<div class="line"><a name="l00142"></a><span class="lineno"> 142</span>&#160; </div>
<div class="line"><a name="l00143"></a><span class="lineno"> 143</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00144"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aaf5cdba2bb5e1dde75cfe528bd81a541"> 144</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aaf5cdba2bb5e1dde75cfe528bd81a541">DatabaseRotatingImp::tune</a>(<span class="keywordtype">int</span> size, <a class="codeRef" href="http://en.cppreference.com/w/cpp/chrono/duration.html">std::chrono::seconds</a> age)</div>
<div class="line"><a name="l00145"></a><span class="lineno"> 145</span>&#160;{</div>
<div class="line"><a name="l00146"></a><span class="lineno"> 146</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">pCache_</a>-&gt;setTargetSize(size);</div>
<div class="line"><a name="l00147"></a><span class="lineno"> 147</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">pCache_</a>-&gt;setTargetAge(age);</div>
<div class="line"><a name="l00148"></a><span class="lineno"> 148</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">nCache_</a>-&gt;setTargetSize(size);</div>
<div class="line"><a name="l00149"></a><span class="lineno"> 149</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">nCache_</a>-&gt;setTargetAge(age);</div>
<div class="line"><a name="l00150"></a><span class="lineno"> 150</span>&#160;}</div>
<div class="line"><a name="l00151"></a><span class="lineno"> 151</span>&#160; </div>
<div class="line"><a name="l00152"></a><span class="lineno"> 152</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00153"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aa67b13515a70659f536b6d1cfeb1c2a2"> 153</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aa67b13515a70659f536b6d1cfeb1c2a2">DatabaseRotatingImp::sweep</a>()</div>
<div class="line"><a name="l00154"></a><span class="lineno"> 154</span>&#160;{</div>
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">pCache_</a>-&gt;sweep();</div>
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">nCache_</a>-&gt;sweep();</div>
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>&#160;}</div>
<div class="line"><a name="l00096"></a><span class="lineno"> 96</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00097"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a7992d0dd009c5b855c331c73872c946d"> 97</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a7992d0dd009c5b855c331c73872c946d">DatabaseRotatingImp::store</a>(</div>
<div class="line"><a name="l00098"></a><span class="lineno"> 98</span>&#160; <a class="code" href="namespaceripple.html#a57d7e7b27df7e719fdf5569f96be60a3">NodeObjectType</a> type,</div>
<div class="line"><a name="l00099"></a><span class="lineno"> 99</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/container/vector.html">Blob</a>&amp;&amp; data,</div>
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span>&#160; <a class="code" href="classripple_1_1base__uint.html">uint256</a> <span class="keyword">const</span>&amp; hash,</div>
<div class="line"><a name="l00101"></a><span class="lineno"> 101</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a>)</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="keyword">auto</span> nObj = <a class="code" href="classripple_1_1NodeObject.html#a841bb9bba547efbd89b240fa9c1cf146">NodeObject::createObject</a>(type, std::move(data), hash);</div>
<div class="line"><a name="l00104"></a><span class="lineno"> 104</span>&#160; </div>
<div class="line"><a name="l00105"></a><span class="lineno"> 105</span>&#160; <span class="keyword">auto</span> <span class="keyword">const</span> backend = [&amp;] {</div>
<div class="line"><a name="l00106"></a><span class="lineno"> 106</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00107"></a><span class="lineno"> 107</span>&#160; <span class="keywordflow">return</span> <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>;</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; backend-&gt;store(nObj);</div>
<div class="line"><a name="l00110"></a><span class="lineno"> 110</span>&#160; </div>
<div class="line"><a name="l00111"></a><span class="lineno"> 111</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#a090e39b8c6733b0dc4553f9e8e705605">storeStats</a>(1, nObj-&gt;getData().size());</div>
<div class="line"><a name="l00112"></a><span class="lineno"> 112</span>&#160;}</div>
<div class="line"><a name="l00113"></a><span class="lineno"> 113</span>&#160; </div>
<div class="line"><a name="l00114"></a><span class="lineno"> 114</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00115"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aa67b13515a70659f536b6d1cfeb1c2a2"> 115</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aa67b13515a70659f536b6d1cfeb1c2a2">DatabaseRotatingImp::sweep</a>()</div>
<div class="line"><a name="l00116"></a><span class="lineno"> 116</span>&#160;{</div>
<div class="line"><a name="l00117"></a><span class="lineno"> 117</span>&#160; <span class="comment">// nothing to do</span></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; </div>
<div class="line"><a name="l00120"></a><span class="lineno"> 120</span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;NodeObject&gt;</a></div>
<div class="line"><a name="l00121"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ac8979815c7dbf46de5ca0dd7b293d5bb"> 121</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ac8979815c7dbf46de5ca0dd7b293d5bb">DatabaseRotatingImp::fetchNodeObject</a>(</div>
<div class="line"><a name="l00122"></a><span class="lineno"> 122</span>&#160; <a class="code" href="classripple_1_1base__uint.html">uint256</a> <span class="keyword">const</span>&amp; hash,</div>
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a>,</div>
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>&#160; <a class="code" href="structripple_1_1NodeStore_1_1FetchReport.html">FetchReport</a>&amp; fetchReport)</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="keyword">auto</span> fetch = [&amp;](<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;Backend&gt;</a> <span class="keyword">const</span>&amp; backend) {</div>
<div class="line"><a name="l00127"></a><span class="lineno"> 127</span>&#160; <a class="code" href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350c">Status</a> status;</div>
<div class="line"><a name="l00128"></a><span class="lineno"> 128</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;NodeObject&gt;</a> nodeObject;</div>
<div class="line"><a name="l00129"></a><span class="lineno"> 129</span>&#160; <span class="keywordflow">try</span></div>
<div class="line"><a name="l00130"></a><span class="lineno"> 130</span>&#160; {</div>
<div class="line"><a name="l00131"></a><span class="lineno"> 131</span>&#160; status = backend-&gt;fetch(hash.<a class="code" href="classripple_1_1base__uint.html#a5342507fe2fb5ac55d578e7e98863f70">data</a>(), &amp;nodeObject);</div>
<div class="line"><a name="l00132"></a><span class="lineno"> 132</span>&#160; }</div>
<div class="line"><a name="l00133"></a><span class="lineno"> 133</span>&#160; <span class="keywordflow">catch</span> (<a class="codeRef" href="http://en.cppreference.com/w/cpp/error/exception.html">std::exception</a> <span class="keyword">const</span>&amp; e)</div>
<div class="line"><a name="l00134"></a><span class="lineno"> 134</span>&#160; {</div>
<div class="line"><a name="l00135"></a><span class="lineno"> 135</span>&#160; JLOG(<a class="code" href="classripple_1_1NodeStore_1_1Database.html#a0d7c3d303adce36199b2c67c4df8a2de">j_</a>.<a class="code" href="classbeast_1_1Journal.html#a3dfb8e2e3eecccdb5cf78ff21bca069c">fatal</a>()) &lt;&lt; <span class="stringliteral">&quot;Exception, &quot;</span> &lt;&lt; e.<a class="codeRef" href="http://en.cppreference.com/w/cpp/error/exception/what.html">what</a>();</div>
<div class="line"><a name="l00136"></a><span class="lineno"> 136</span>&#160; <a class="code" href="namespaceripple.html#ad99788f1aca6ce31a1fe8365eee1bba3">Rethrow</a>();</div>
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span>&#160; }</div>
<div class="line"><a name="l00138"></a><span class="lineno"> 138</span>&#160; </div>
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span>&#160; <span class="keywordflow">switch</span> (status)</div>
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span>&#160; {</div>
<div class="line"><a name="l00141"></a><span class="lineno"> 141</span>&#160; <span class="keywordflow">case</span> <a class="code" href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350ca852178e08b8b1f2eb19fd271e63830ef">ok</a>:</div>
<div class="line"><a name="l00142"></a><span class="lineno"> 142</span>&#160; ++<a class="code" href="classripple_1_1NodeStore_1_1Database.html#a89497b9b4c5530b58040931489015d30">fetchHitCount_</a>;</div>
<div class="line"><a name="l00143"></a><span class="lineno"> 143</span>&#160; <span class="keywordflow">if</span> (nodeObject)</div>
<div class="line"><a name="l00144"></a><span class="lineno"> 144</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#a04150d23aa2acaf016d4ca40bd10804a">fetchSz_</a> += nodeObject-&gt;getData().size();</div>
<div class="line"><a name="l00145"></a><span class="lineno"> 145</span>&#160; <span class="keywordflow">break</span>;</div>
<div class="line"><a name="l00146"></a><span class="lineno"> 146</span>&#160; <span class="keywordflow">case</span> <a class="code" href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350cafa8056068943efe12560207a8a503db8">notFound</a>:</div>
<div class="line"><a name="l00147"></a><span class="lineno"> 147</span>&#160; <span class="keywordflow">break</span>;</div>
<div class="line"><a name="l00148"></a><span class="lineno"> 148</span>&#160; <span class="keywordflow">case</span> <a class="code" href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350ca915a2fc67fa0633b4995f8c1e4d54bdf">dataCorrupt</a>:</div>
<div class="line"><a name="l00149"></a><span class="lineno"> 149</span>&#160; JLOG(<a class="code" href="classripple_1_1NodeStore_1_1Database.html#a0d7c3d303adce36199b2c67c4df8a2de">j_</a>.<a class="code" href="classbeast_1_1Journal.html#a3dfb8e2e3eecccdb5cf78ff21bca069c">fatal</a>()) &lt;&lt; <span class="stringliteral">&quot;Corrupt NodeObject #&quot;</span> &lt;&lt; hash;</div>
<div class="line"><a name="l00150"></a><span class="lineno"> 150</span>&#160; <span class="keywordflow">break</span>;</div>
<div class="line"><a name="l00151"></a><span class="lineno"> 151</span>&#160; <span class="keywordflow">default</span>:</div>
<div class="line"><a name="l00152"></a><span class="lineno"> 152</span>&#160; JLOG(<a class="code" href="classripple_1_1NodeStore_1_1Database.html#a0d7c3d303adce36199b2c67c4df8a2de">j_</a>.<a class="code" href="classbeast_1_1Journal.html#ad8fefe3e8ad583e1ed1bf02094ac3d8f">warn</a>()) &lt;&lt; <span class="stringliteral">&quot;Unknown status=&quot;</span> &lt;&lt; status;</div>
<div class="line"><a name="l00153"></a><span class="lineno"> 153</span>&#160; <span class="keywordflow">break</span>;</div>
<div class="line"><a name="l00154"></a><span class="lineno"> 154</span>&#160; }</div>
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>&#160; </div>
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>&#160; <span class="keywordflow">return</span> nodeObject;</div>
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>&#160; };</div>
<div class="line"><a name="l00158"></a><span class="lineno"> 158</span>&#160; </div>
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span>&#160;<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;NodeObject&gt;</a></div>
<div class="line"><a name="l00160"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ac8979815c7dbf46de5ca0dd7b293d5bb"> 160</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ac8979815c7dbf46de5ca0dd7b293d5bb">DatabaseRotatingImp::fetchNodeObject</a>(</div>
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span>&#160; <a class="code" href="classripple_1_1base__uint.html">uint256</a> <span class="keyword">const</span>&amp; hash,</div>
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/types/integer.html">std::uint32_t</a>,</div>
<div class="line"><a name="l00163"></a><span class="lineno"> 163</span>&#160; <a class="code" href="structripple_1_1NodeStore_1_1FetchReport.html">FetchReport</a>&amp; fetchReport)</div>
<div class="line"><a name="l00164"></a><span class="lineno"> 164</span>&#160;{</div>
<div class="line"><a name="l00165"></a><span class="lineno"> 165</span>&#160; <span class="keyword">auto</span> fetch = [&amp;](<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;Backend&gt;</a> <span class="keyword">const</span>&amp; backend) {</div>
<div class="line"><a name="l00166"></a><span class="lineno"> 166</span>&#160; <a class="code" href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350c">Status</a> status;</div>
<div class="line"><a name="l00167"></a><span class="lineno"> 167</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;NodeObject&gt;</a> nodeObject;</div>
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>&#160; <span class="keywordflow">try</span></div>
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span>&#160; {</div>
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span>&#160; status = backend-&gt;fetch(hash.<a class="code" href="classripple_1_1base__uint.html#a5342507fe2fb5ac55d578e7e98863f70">data</a>(), &amp;nodeObject);</div>
<div class="line"><a name="l00171"></a><span class="lineno"> 171</span>&#160; }</div>
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>&#160; <span class="keywordflow">catch</span> (<a class="codeRef" href="http://en.cppreference.com/w/cpp/error/exception.html">std::exception</a> <span class="keyword">const</span>&amp; e)</div>
<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>&#160; {</div>
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>&#160; JLOG(<a class="code" href="classripple_1_1NodeStore_1_1Database.html#a0d7c3d303adce36199b2c67c4df8a2de">j_</a>.<a class="code" href="classbeast_1_1Journal.html#a3dfb8e2e3eecccdb5cf78ff21bca069c">fatal</a>()) &lt;&lt; <span class="stringliteral">&quot;Exception, &quot;</span> &lt;&lt; e.<a class="codeRef" href="http://en.cppreference.com/w/cpp/error/exception/what.html">what</a>();</div>
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span>&#160; <a class="code" href="namespaceripple.html#ad99788f1aca6ce31a1fe8365eee1bba3">Rethrow</a>();</div>
<div class="line"><a name="l00176"></a><span class="lineno"> 176</span>&#160; }</div>
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span>&#160; </div>
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>&#160; <span class="keywordflow">switch</span> (status)</div>
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span>&#160; {</div>
<div class="line"><a name="l00180"></a><span class="lineno"> 180</span>&#160; <span class="keywordflow">case</span> <a class="code" href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350ca852178e08b8b1f2eb19fd271e63830ef">ok</a>:</div>
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span>&#160; ++<a class="code" href="classripple_1_1NodeStore_1_1Database.html#a89497b9b4c5530b58040931489015d30">fetchHitCount_</a>;</div>
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>&#160; <span class="keywordflow">if</span> (nodeObject)</div>
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1Database.html#a04150d23aa2acaf016d4ca40bd10804a">fetchSz_</a> += nodeObject-&gt;getData().size();</div>
<div class="line"><a name="l00184"></a><span class="lineno"> 184</span>&#160; <span class="keywordflow">break</span>;</div>
<div class="line"><a name="l00185"></a><span class="lineno"> 185</span>&#160; <span class="keywordflow">case</span> <a class="code" href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350cafa8056068943efe12560207a8a503db8">notFound</a>:</div>
<div class="line"><a name="l00186"></a><span class="lineno"> 186</span>&#160; <span class="keywordflow">break</span>;</div>
<div class="line"><a name="l00187"></a><span class="lineno"> 187</span>&#160; <span class="keywordflow">case</span> <a class="code" href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350ca915a2fc67fa0633b4995f8c1e4d54bdf">dataCorrupt</a>:</div>
<div class="line"><a name="l00188"></a><span class="lineno"> 188</span>&#160; JLOG(<a class="code" href="classripple_1_1NodeStore_1_1Database.html#a0d7c3d303adce36199b2c67c4df8a2de">j_</a>.<a class="code" href="classbeast_1_1Journal.html#a3dfb8e2e3eecccdb5cf78ff21bca069c">fatal</a>()) &lt;&lt; <span class="stringliteral">&quot;Corrupt NodeObject #&quot;</span> &lt;&lt; hash;</div>
<div class="line"><a name="l00189"></a><span class="lineno"> 189</span>&#160; <span class="keywordflow">break</span>;</div>
<div class="line"><a name="l00190"></a><span class="lineno"> 190</span>&#160; <span class="keywordflow">default</span>:</div>
<div class="line"><a name="l00191"></a><span class="lineno"> 191</span>&#160; JLOG(<a class="code" href="classripple_1_1NodeStore_1_1Database.html#a0d7c3d303adce36199b2c67c4df8a2de">j_</a>.<a class="code" href="classbeast_1_1Journal.html#ad8fefe3e8ad583e1ed1bf02094ac3d8f">warn</a>()) &lt;&lt; <span class="stringliteral">&quot;Unknown status=&quot;</span> &lt;&lt; status;</div>
<div class="line"><a name="l00192"></a><span class="lineno"> 192</span>&#160; <span class="keywordflow">break</span>;</div>
<div class="line"><a name="l00193"></a><span class="lineno"> 193</span>&#160; }</div>
<div class="line"><a name="l00194"></a><span class="lineno"> 194</span>&#160; </div>
<div class="line"><a name="l00195"></a><span class="lineno"> 195</span>&#160; <span class="keywordflow">return</span> nodeObject;</div>
<div class="line"><a name="l00196"></a><span class="lineno"> 196</span>&#160; };</div>
<div class="line"><a name="l00197"></a><span class="lineno"> 197</span>&#160; </div>
<div class="line"><a name="l00198"></a><span class="lineno"> 198</span>&#160; <span class="comment">// See if the node object exists in the cache</span></div>
<div class="line"><a name="l00199"></a><span class="lineno"> 199</span>&#160; <span class="keyword">auto</span> nodeObject{<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">pCache_</a>-&gt;fetch(hash)};</div>
<div class="line"><a name="l00200"></a><span class="lineno"> 200</span>&#160; <span class="keywordflow">if</span> (!nodeObject &amp;&amp; !<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">nCache_</a>-&gt;touch_if_exists(hash))</div>
<div class="line"><a name="l00201"></a><span class="lineno"> 201</span>&#160; {</div>
<div class="line"><a name="l00202"></a><span class="lineno"> 202</span>&#160; <span class="keyword">auto</span> [writable, archive] = [&amp;] {</div>
<div class="line"><a name="l00203"></a><span class="lineno"> 203</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>&#160; <span class="keywordflow">return</span> <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/pair/make_pair.html">std::make_pair</a>(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>, <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>);</div>
<div class="line"><a name="l00205"></a><span class="lineno"> 205</span>&#160; }();</div>
<div class="line"><a name="l00206"></a><span class="lineno"> 206</span>&#160; </div>
<div class="line"><a name="l00207"></a><span class="lineno"> 207</span>&#160; fetchReport.<a class="code" href="structripple_1_1NodeStore_1_1FetchReport.html#a3063c18d4ab5927e8a3cb129745a2ca3">wentToDisk</a> = <span class="keyword">true</span>;</div>
<div class="line"><a name="l00208"></a><span class="lineno"> 208</span>&#160; </div>
<div class="line"><a name="l00209"></a><span class="lineno"> 209</span>&#160; <span class="comment">// Try to fetch from the writable backend</span></div>
<div class="line"><a name="l00210"></a><span class="lineno"> 210</span>&#160; nodeObject = fetch(writable);</div>
<div class="line"><a name="l00211"></a><span class="lineno"> 211</span>&#160; <span class="keywordflow">if</span> (!nodeObject)</div>
<div class="line"><a name="l00212"></a><span class="lineno"> 212</span>&#160; {</div>
<div class="line"><a name="l00213"></a><span class="lineno"> 213</span>&#160; <span class="comment">// Otherwise try to fetch from the archive backend</span></div>
<div class="line"><a name="l00214"></a><span class="lineno"> 214</span>&#160; nodeObject = fetch(archive);</div>
<div class="line"><a name="l00215"></a><span class="lineno"> 215</span>&#160; <span class="keywordflow">if</span> (nodeObject)</div>
<div class="line"><a name="l00216"></a><span class="lineno"> 216</span>&#160; {</div>
<div class="line"><a name="l00217"></a><span class="lineno"> 217</span>&#160; {</div>
<div class="line"><a name="l00218"></a><span class="lineno"> 218</span>&#160; <span class="comment">// Refresh the writable backend pointer</span></div>
<div class="line"><a name="l00219"></a><span class="lineno"> 219</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00220"></a><span class="lineno"> 220</span>&#160; writable = <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>;</div>
<div class="line"><a name="l00221"></a><span class="lineno"> 221</span>&#160; }</div>
<div class="line"><a name="l00222"></a><span class="lineno"> 222</span>&#160; </div>
<div class="line"><a name="l00223"></a><span class="lineno"> 223</span>&#160; <span class="comment">// Update writable backend with data from the archive backend</span></div>
<div class="line"><a name="l00224"></a><span class="lineno"> 224</span>&#160; writable-&gt;store(nodeObject);</div>
<div class="line"><a name="l00225"></a><span class="lineno"> 225</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">nCache_</a>-&gt;erase(hash);</div>
<div class="line"><a name="l00226"></a><span class="lineno"> 226</span>&#160; }</div>
<div class="line"><a name="l00227"></a><span class="lineno"> 227</span>&#160; }</div>
<div class="line"><a name="l00228"></a><span class="lineno"> 228</span>&#160; </div>
<div class="line"><a name="l00229"></a><span class="lineno"> 229</span>&#160; <span class="keywordflow">if</span> (!nodeObject)</div>
<div class="line"><a name="l00230"></a><span class="lineno"> 230</span>&#160; {</div>
<div class="line"><a name="l00231"></a><span class="lineno"> 231</span>&#160; <span class="comment">// Just in case a write occurred</span></div>
<div class="line"><a name="l00232"></a><span class="lineno"> 232</span>&#160; nodeObject = <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">pCache_</a>-&gt;fetch(hash);</div>
<div class="line"><a name="l00233"></a><span class="lineno"> 233</span>&#160; <span class="keywordflow">if</span> (!nodeObject)</div>
<div class="line"><a name="l00234"></a><span class="lineno"> 234</span>&#160; <span class="comment">// We give up</span></div>
<div class="line"><a name="l00235"></a><span class="lineno"> 235</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">nCache_</a>-&gt;insert(hash);</div>
<div class="line"><a name="l00236"></a><span class="lineno"> 236</span>&#160; }</div>
<div class="line"><a name="l00237"></a><span class="lineno"> 237</span>&#160; <span class="keywordflow">else</span></div>
<div class="line"><a name="l00238"></a><span class="lineno"> 238</span>&#160; {</div>
<div class="line"><a name="l00239"></a><span class="lineno"> 239</span>&#160; fetchReport.<a class="code" href="structripple_1_1NodeStore_1_1FetchReport.html#a7ab35eb8a30af6dbc6ee916ccf60474d">wasFound</a> = <span class="keyword">true</span>;</div>
<div class="line"><a name="l00240"></a><span class="lineno"> 240</span>&#160; </div>
<div class="line"><a name="l00241"></a><span class="lineno"> 241</span>&#160; <span class="comment">// Ensure all threads get the same object</span></div>
<div class="line"><a name="l00242"></a><span class="lineno"> 242</span>&#160; <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">pCache_</a>-&gt;canonicalize_replace_client(hash, nodeObject);</div>
<div class="line"><a name="l00243"></a><span class="lineno"> 243</span>&#160; </div>
<div class="line"><a name="l00244"></a><span class="lineno"> 244</span>&#160; <span class="comment">// Since this was a &#39;hard&#39; fetch, we will log it</span></div>
<div class="line"><a name="l00245"></a><span class="lineno"> 245</span>&#160; JLOG(<a class="code" href="classripple_1_1NodeStore_1_1Database.html#a0d7c3d303adce36199b2c67c4df8a2de">j_</a>.<a class="code" href="classbeast_1_1Journal.html#abbe082bd27ca0f1d1365af2824e4f85b">trace</a>()) &lt;&lt; <span class="stringliteral">&quot;HOS: &quot;</span> &lt;&lt; hash &lt;&lt; <span class="stringliteral">&quot; fetch: in shard db&quot;</span>;</div>
<div class="line"><a name="l00246"></a><span class="lineno"> 246</span>&#160; }</div>
<div class="line"><a name="l00247"></a><span class="lineno"> 247</span>&#160; }</div>
<div class="line"><a name="l00248"></a><span class="lineno"> 248</span>&#160; </div>
<div class="line"><a name="l00249"></a><span class="lineno"> 249</span>&#160; <span class="keywordflow">return</span> nodeObject;</div>
<div class="line"><a name="l00250"></a><span class="lineno"> 250</span>&#160;}</div>
<div class="line"><a name="l00251"></a><span class="lineno"> 251</span>&#160; </div>
<div class="line"><a name="l00252"></a><span class="lineno"> 252</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00253"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aee99c67c55042890a37368f5d17620d4"> 253</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aee99c67c55042890a37368f5d17620d4">DatabaseRotatingImp::for_each</a>(</div>
<div class="line"><a name="l00254"></a><span class="lineno"> 254</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/functional/function.html">std::function</a>&lt;<span class="keywordtype">void</span>(<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;NodeObject&gt;</a>)&gt; f)</div>
<div class="line"><a name="l00255"></a><span class="lineno"> 255</span>&#160;{</div>
<div class="line"><a name="l00256"></a><span class="lineno"> 256</span>&#160; <span class="keyword">auto</span> [writable, archive] = [&amp;] {</div>
<div class="line"><a name="l00257"></a><span class="lineno"> 257</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00258"></a><span class="lineno"> 258</span>&#160; <span class="keywordflow">return</span> <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/pair/make_pair.html">std::make_pair</a>(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>, <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>);</div>
<div class="line"><a name="l00259"></a><span class="lineno"> 259</span>&#160; }();</div>
<div class="line"><a name="l00260"></a><span class="lineno"> 260</span>&#160; </div>
<div class="line"><a name="l00261"></a><span class="lineno"> 261</span>&#160; <span class="comment">// Iterate the writable backend</span></div>
<div class="line"><a name="l00262"></a><span class="lineno"> 262</span>&#160; writable-&gt;for_each(f);</div>
<div class="line"><a name="l00263"></a><span class="lineno"> 263</span>&#160; </div>
<div class="line"><a name="l00264"></a><span class="lineno"> 264</span>&#160; <span class="comment">// Iterate the archive backend</span></div>
<div class="line"><a name="l00265"></a><span class="lineno"> 265</span>&#160; archive-&gt;for_each(f);</div>
<div class="line"><a name="l00266"></a><span class="lineno"> 266</span>&#160;}</div>
<div class="line"><a name="l00267"></a><span class="lineno"> 267</span>&#160; </div>
<div class="line"><a name="l00268"></a><span class="lineno"> 268</span>&#160;} <span class="comment">// namespace NodeStore</span></div>
<div class="line"><a name="l00269"></a><span class="lineno"> 269</span>&#160;} <span class="comment">// namespace ripple</span></div>
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span>&#160; <span class="comment">// See if the node object exists in the cache</span></div>
<div class="line"><a name="l00160"></a><span class="lineno"> 160</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;NodeObject&gt;</a> nodeObject;</div>
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span>&#160; </div>
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span>&#160; <span class="keyword">auto</span> [writable, archive] = [&amp;] {</div>
<div class="line"><a name="l00163"></a><span class="lineno"> 163</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00164"></a><span class="lineno"> 164</span>&#160; <span class="keywordflow">return</span> <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/pair/make_pair.html">std::make_pair</a>(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>, <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>);</div>
<div class="line"><a name="l00165"></a><span class="lineno"> 165</span>&#160; }();</div>
<div class="line"><a name="l00166"></a><span class="lineno"> 166</span>&#160; </div>
<div class="line"><a name="l00167"></a><span class="lineno"> 167</span>&#160; <span class="comment">// Try to fetch from the writable backend</span></div>
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>&#160; nodeObject = fetch(writable);</div>
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span>&#160; <span class="keywordflow">if</span> (!nodeObject)</div>
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span>&#160; {</div>
<div class="line"><a name="l00171"></a><span class="lineno"> 171</span>&#160; <span class="comment">// Otherwise try to fetch from the archive backend</span></div>
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>&#160; nodeObject = fetch(archive);</div>
<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>&#160; <span class="keywordflow">if</span> (nodeObject)</div>
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>&#160; {</div>
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span>&#160; {</div>
<div class="line"><a name="l00176"></a><span class="lineno"> 176</span>&#160; <span class="comment">// Refresh the writable backend pointer</span></div>
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>&#160; writable = <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>;</div>
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span>&#160; }</div>
<div class="line"><a name="l00180"></a><span class="lineno"> 180</span>&#160; </div>
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span>&#160; <span class="comment">// Update writable backend with data from the archive backend</span></div>
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>&#160; writable-&gt;store(nodeObject);</div>
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span>&#160; }</div>
<div class="line"><a name="l00184"></a><span class="lineno"> 184</span>&#160; }</div>
<div class="line"><a name="l00185"></a><span class="lineno"> 185</span>&#160; </div>
<div class="line"><a name="l00186"></a><span class="lineno"> 186</span>&#160; <span class="keywordflow">if</span> (nodeObject)</div>
<div class="line"><a name="l00187"></a><span class="lineno"> 187</span>&#160; fetchReport.<a class="code" href="structripple_1_1NodeStore_1_1FetchReport.html#a7ab35eb8a30af6dbc6ee916ccf60474d">wasFound</a> = <span class="keyword">true</span>;</div>
<div class="line"><a name="l00188"></a><span class="lineno"> 188</span>&#160; </div>
<div class="line"><a name="l00189"></a><span class="lineno"> 189</span>&#160; <span class="keywordflow">return</span> nodeObject;</div>
<div class="line"><a name="l00190"></a><span class="lineno"> 190</span>&#160;}</div>
<div class="line"><a name="l00191"></a><span class="lineno"> 191</span>&#160; </div>
<div class="line"><a name="l00192"></a><span class="lineno"> 192</span>&#160;<span class="keywordtype">void</span></div>
<div class="line"><a name="l00193"></a><span class="lineno"><a class="line" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aee99c67c55042890a37368f5d17620d4"> 193</a></span>&#160;<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aee99c67c55042890a37368f5d17620d4">DatabaseRotatingImp::for_each</a>(</div>
<div class="line"><a name="l00194"></a><span class="lineno"> 194</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/functional/function.html">std::function</a>&lt;<span class="keywordtype">void</span>(<a class="codeRef" href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr&lt;NodeObject&gt;</a>)&gt; f)</div>
<div class="line"><a name="l00195"></a><span class="lineno"> 195</span>&#160;{</div>
<div class="line"><a name="l00196"></a><span class="lineno"> 196</span>&#160; <span class="keyword">auto</span> [writable, archive] = [&amp;] {</div>
<div class="line"><a name="l00197"></a><span class="lineno"> 197</span>&#160; <a class="codeRef" href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a> lock(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">mutex_</a>);</div>
<div class="line"><a name="l00198"></a><span class="lineno"> 198</span>&#160; <span class="keywordflow">return</span> <a class="codeRef" href="http://en.cppreference.com/w/cpp/utility/pair/make_pair.html">std::make_pair</a>(<a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">writableBackend_</a>, <a class="code" href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">archiveBackend_</a>);</div>
<div class="line"><a name="l00199"></a><span class="lineno"> 199</span>&#160; }();</div>
<div class="line"><a name="l00200"></a><span class="lineno"> 200</span>&#160; </div>
<div class="line"><a name="l00201"></a><span class="lineno"> 201</span>&#160; <span class="comment">// Iterate the writable backend</span></div>
<div class="line"><a name="l00202"></a><span class="lineno"> 202</span>&#160; writable-&gt;for_each(f);</div>
<div class="line"><a name="l00203"></a><span class="lineno"> 203</span>&#160; </div>
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>&#160; <span class="comment">// Iterate the archive backend</span></div>
<div class="line"><a name="l00205"></a><span class="lineno"> 205</span>&#160; archive-&gt;for_each(f);</div>
<div class="line"><a name="l00206"></a><span class="lineno"> 206</span>&#160;}</div>
<div class="line"><a name="l00207"></a><span class="lineno"> 207</span>&#160; </div>
<div class="line"><a name="l00208"></a><span class="lineno"> 208</span>&#160;} <span class="comment">// namespace NodeStore</span></div>
<div class="line"><a name="l00209"></a><span class="lineno"> 209</span>&#160;} <span class="comment">// namespace ripple</span></div>
</div><!-- fragment --></div><!-- contents -->
<div class="ttc" id="aclassbeast_1_1Journal_html_a3dfb8e2e3eecccdb5cf78ff21bca069c"><div class="ttname"><a href="classbeast_1_1Journal.html#a3dfb8e2e3eecccdb5cf78ff21bca069c">beast::Journal::fatal</a></div><div class="ttdeci">Stream fatal() const</div><div class="ttdef"><b>Definition:</b> <a href="Journal_8h_source.html#l00339">Journal.h:339</a></div></div>
<div class="ttc" id="aclassripple_1_1Section_html"><div class="ttname"><a href="classripple_1_1Section.html">ripple::Section</a></div><div class="ttdoc">Holds a collection of configuration values.</div><div class="ttdef"><b>Definition:</b> <a href="BasicConfig_8h_source.html#l00043">BasicConfig.h:43</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a76f256f68048bc81a0d034f7226387b8"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a76f256f68048bc81a0d034f7226387b8">ripple::NodeStore::DatabaseRotatingImp::rotateWithLock</a></div><div class="ttdeci">void rotateWithLock(std::function&lt; std::unique_ptr&lt; NodeStore::Backend &gt;(std::string const &amp;writableBackendName)&gt; const &amp;f) override</div><div class="ttdoc">Rotates the backends.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00059">DatabaseRotatingImp.cpp:59</a></div></div>
<div class="ttc" id="anamespaceripple_1_1NodeStore_html_ab026118fd22b5e7db14b5dea6938aaa8a82fcd9983079b023efaf136078d3d2d3"><div class="ttname"><a href="namespaceripple_1_1NodeStore.html#ab026118fd22b5e7db14b5dea6938aaa8a82fcd9983079b023efaf136078d3d2d3">ripple::NodeStore::cacheTargetSize</a></div><div class="ttdeci">@ cacheTargetSize</div><div class="ttdef"><b>Definition:</b> <a href="nodestore_2impl_2Tuning_8h_source.html#l00028">nodestore/impl/Tuning.h:28</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a44b1eace70e02649d16668ca920531cb"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">ripple::NodeStore::DatabaseRotatingImp::archiveBackend_</a></div><div class="ttdeci">std::shared_ptr&lt; Backend &gt; archiveBackend_</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8h_source.html#l00113">DatabaseRotatingImp.h:113</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html">ripple::NodeStore::Database</a></div><div class="ttdoc">Persistency layer for NodeObject.</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00053">Database.h:53</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a76f256f68048bc81a0d034f7226387b8"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a76f256f68048bc81a0d034f7226387b8">ripple::NodeStore::DatabaseRotatingImp::rotateWithLock</a></div><div class="ttdeci">void rotateWithLock(std::function&lt; std::unique_ptr&lt; NodeStore::Backend &gt;(std::string const &amp;writableBackendName)&gt; const &amp;f) override</div><div class="ttdoc">Rotates the backends.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00048">DatabaseRotatingImp.cpp:48</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a44b1eace70e02649d16668ca920531cb"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a44b1eace70e02649d16668ca920531cb">ripple::NodeStore::DatabaseRotatingImp::archiveBackend_</a></div><div class="ttdeci">std::shared_ptr&lt; Backend &gt; archiveBackend_</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8h_source.html#l00084">DatabaseRotatingImp.h:84</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html">ripple::NodeStore::Database</a></div><div class="ttdoc">Persistency layer for NodeObject.</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00052">Database.h:52</a></div></div>
<div class="ttc" id="abasic_string_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/string/basic_string.html">std::string</a></div><div class="ttdoc">STL class.</div></div>
<div class="ttc" id="ashared_ptr_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/memory/shared_ptr.html">std::shared_ptr</a></div><div class="ttdoc">STL class.</div></div>
<div class="ttc" id="aclassripple_1_1TaggedCache_html"><div class="ttname"><a href="classripple_1_1TaggedCache.html">ripple::TaggedCache</a></div><div class="ttdoc">Map/cache combination.</div><div class="ttdef"><b>Definition:</b> <a href="TaggedCache_8h_source.html#l00052">TaggedCache.h:52</a></div></div>
<div class="ttc" id="aexception_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/error/exception.html">std::exception</a></div><div class="ttdoc">STL class.</div></div>
<div class="ttc" id="aclassbeast_1_1Journal_html_abbe082bd27ca0f1d1365af2824e4f85b"><div class="ttname"><a href="classbeast_1_1Journal.html#abbe082bd27ca0f1d1365af2824e4f85b">beast::Journal::trace</a></div><div class="ttdeci">Stream trace() const</div><div class="ttdoc">Severity stream access functions.</div><div class="ttdef"><b>Definition:</b> <a href="Journal_8h_source.html#l00309">Journal.h:309</a></div></div>
<div class="ttc" id="anamespaceripple_1_1NodeStore_html_af127c2e4fc73b5d35647147ef45b350ca852178e08b8b1f2eb19fd271e63830ef"><div class="ttname"><a href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350ca852178e08b8b1f2eb19fd271e63830ef">ripple::NodeStore::ok</a></div><div class="ttdeci">@ ok</div><div class="ttdef"><b>Definition:</b> <a href="nodestore_2Types_8h_source.html#l00045">nodestore/Types.h:45</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_aa67b13515a70659f536b6d1cfeb1c2a2"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aa67b13515a70659f536b6d1cfeb1c2a2">ripple::NodeStore::DatabaseRotatingImp::sweep</a></div><div class="ttdeci">void sweep() override</div><div class="ttdoc">Remove expired entries from the positive and negative caches.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00153">DatabaseRotatingImp.cpp:153</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_aaf5cdba2bb5e1dde75cfe528bd81a541"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aaf5cdba2bb5e1dde75cfe528bd81a541">ripple::NodeStore::DatabaseRotatingImp::tune</a></div><div class="ttdeci">void tune(int size, std::chrono::seconds age) override</div><div class="ttdoc">Set the maximum number of entries and maximum cache age for both caches.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00144">DatabaseRotatingImp.cpp:144</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a730a87cf8b617a8afb30e2531ede0f81"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a730a87cf8b617a8afb30e2531ede0f81">ripple::NodeStore::Database::fdRequired_</a></div><div class="ttdeci">int fdRequired_</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00249">Database.h:249</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_aa67b13515a70659f536b6d1cfeb1c2a2"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aa67b13515a70659f536b6d1cfeb1c2a2">ripple::NodeStore::DatabaseRotatingImp::sweep</a></div><div class="ttdeci">void sweep() override</div><div class="ttdoc">Remove expired entries from the positive and negative caches.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00115">DatabaseRotatingImp.cpp:115</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a730a87cf8b617a8afb30e2531ede0f81"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a730a87cf8b617a8afb30e2531ede0f81">ripple::NodeStore::Database::fdRequired_</a></div><div class="ttdeci">int fdRequired_</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00236">Database.h:236</a></div></div>
<div class="ttc" id="avector_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/container/vector.html">std::vector&lt; unsigned char &gt;</a></div></div>
<div class="ttc" id="anamespaceripple_html_a57d7e7b27df7e719fdf5569f96be60a3"><div class="ttname"><a href="namespaceripple.html#a57d7e7b27df7e719fdf5569f96be60a3">ripple::NodeObjectType</a></div><div class="ttdeci">NodeObjectType</div><div class="ttdoc">The types of node objects.</div><div class="ttdef"><b>Definition:</b> <a href="NodeObject_8h_source.html#l00032">NodeObject.h:32</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeObject_html_a841bb9bba547efbd89b240fa9c1cf146"><div class="ttname"><a href="classripple_1_1NodeObject.html#a841bb9bba547efbd89b240fa9c1cf146">ripple::NodeObject::createObject</a></div><div class="ttdeci">static std::shared_ptr&lt; NodeObject &gt; createObject(NodeObjectType type, Blob &amp;&amp;data, uint256 const &amp;hash)</div><div class="ttdoc">Create an object from fields.</div><div class="ttdef"><b>Definition:</b> <a href="NodeObject_8cpp_source.html#l00037">NodeObject.cpp:37</a></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="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_ac82d8cd599ee29280d5cf6796ff01332"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ac82d8cd599ee29280d5cf6796ff01332">ripple::NodeStore::DatabaseRotatingImp::DatabaseRotatingImp</a></div><div class="ttdeci">DatabaseRotatingImp()=delete</div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_ac8979815c7dbf46de5ca0dd7b293d5bb"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ac8979815c7dbf46de5ca0dd7b293d5bb">ripple::NodeStore::DatabaseRotatingImp::fetchNodeObject</a></div><div class="ttdeci">std::shared_ptr&lt; NodeObject &gt; fetchNodeObject(uint256 const &amp;hash, std::uint32_t, FetchReport &amp;fetchReport) override</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00160">DatabaseRotatingImp.cpp:160</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_ac8979815c7dbf46de5ca0dd7b293d5bb"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ac8979815c7dbf46de5ca0dd7b293d5bb">ripple::NodeStore::DatabaseRotatingImp::fetchNodeObject</a></div><div class="ttdeci">std::shared_ptr&lt; NodeObject &gt; fetchNodeObject(uint256 const &amp;hash, std::uint32_t, FetchReport &amp;fetchReport) override</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00121">DatabaseRotatingImp.cpp:121</a></div></div>
<div class="ttc" id="aclassbeast_1_1Journal_html_ad8fefe3e8ad583e1ed1bf02094ac3d8f"><div class="ttname"><a href="classbeast_1_1Journal.html#ad8fefe3e8ad583e1ed1bf02094ac3d8f">beast::Journal::warn</a></div><div class="ttdeci">Stream warn() const</div><div class="ttdef"><b>Definition:</b> <a href="Journal_8h_source.html#l00327">Journal.h:327</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a04150d23aa2acaf016d4ca40bd10804a"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a04150d23aa2acaf016d4ca40bd10804a">ripple::NodeStore::Database::fetchSz_</a></div><div class="ttdeci">std::atomic&lt; std::uint32_t &gt; fetchSz_</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00252">Database.h:252</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a04150d23aa2acaf016d4ca40bd10804a"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a04150d23aa2acaf016d4ca40bd10804a">ripple::NodeStore::Database::fetchSz_</a></div><div class="ttdeci">std::atomic&lt; std::uint32_t &gt; fetchSz_</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00239">Database.h:239</a></div></div>
<div class="ttc" id="alock_guard_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/thread/lock_guard.html">std::lock_guard</a></div><div class="ttdoc">STL class.</div></div>
<div class="ttc" id="astructripple_1_1NodeStore_1_1FetchReport_html"><div class="ttname"><a href="structripple_1_1NodeStore_1_1FetchReport.html">ripple::NodeStore::FetchReport</a></div><div class="ttdoc">Contains information about a fetch operation.</div><div class="ttdef"><b>Definition:</b> <a href="ripple_2nodestore_2Scheduler_8h_source.html#l00032">ripple/nodestore/Scheduler.h:32</a></div></div>
<div class="ttc" id="anamespaceripple_html_ac70521ab6e1277870a9e400e7a08e937"><div class="ttname"><a href="namespaceripple.html#ac70521ab6e1277870a9e400e7a08e937">ripple::stopwatch</a></div><div class="ttdeci">Stopwatch &amp; stopwatch()</div><div class="ttdoc">Returns an instance of a wall clock.</div><div class="ttdef"><b>Definition:</b> <a href="chrono_8h_source.html#l00086">chrono.h:86</a></div></div>
<div class="ttc" id="afunction_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/utility/functional/function.html">std::function</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a9c3f2d7e8b7e4cca14afe2177c1466b3"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a9c3f2d7e8b7e4cca14afe2177c1466b3">ripple::NodeStore::DatabaseRotatingImp::getName</a></div><div class="ttdeci">std::string getName() const override</div><div class="ttdoc">Retrieve the name associated with this backend.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00072">DatabaseRotatingImp.cpp:72</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a89497b9b4c5530b58040931489015d30"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a89497b9b4c5530b58040931489015d30">ripple::NodeStore::Database::fetchHitCount_</a></div><div class="ttdeci">std::atomic&lt; std::uint32_t &gt; fetchHitCount_</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00251">Database.h:251</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a9c3f2d7e8b7e4cca14afe2177c1466b3"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a9c3f2d7e8b7e4cca14afe2177c1466b3">ripple::NodeStore::DatabaseRotatingImp::getName</a></div><div class="ttdeci">std::string getName() const override</div><div class="ttdoc">Retrieve the name associated with this backend.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00061">DatabaseRotatingImp.cpp:61</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a89497b9b4c5530b58040931489015d30"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a89497b9b4c5530b58040931489015d30">ripple::NodeStore::Database::fetchHitCount_</a></div><div class="ttdeci">std::atomic&lt; std::uint32_t &gt; fetchHitCount_</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00238">Database.h:238</a></div></div>
<div class="ttc" id="aclassripple_1_1base__uint_html_a5342507fe2fb5ac55d578e7e98863f70"><div class="ttname"><a href="classripple_1_1base__uint.html#a5342507fe2fb5ac55d578e7e98863f70">ripple::base_uint::data</a></div><div class="ttdeci">pointer data()</div><div class="ttdef"><b>Definition:</b> <a href="base__uint_8h_source.html#l00113">base_uint.h:113</a></div></div>
<div class="ttc" id="aclassripple_1_1Stoppable_html_adea135697761febf430a8628814c7902"><div class="ttname"><a href="classripple_1_1Stoppable.html#adea135697761febf430a8628814c7902">ripple::Stoppable::setParent</a></div><div class="ttdeci">void setParent(Stoppable &amp;parent)</div><div class="ttdoc">Set the parent of this Stoppable.</div><div class="ttdef"><b>Definition:</b> <a href="Stoppable_8cpp_source.html#l00043">Stoppable.cpp:43</a></div></div>
<div class="ttc" id="anamespaceripple_1_1NodeStore_html_af127c2e4fc73b5d35647147ef45b350cafa8056068943efe12560207a8a503db8"><div class="ttname"><a href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350cafa8056068943efe12560207a8a503db8">ripple::NodeStore::notFound</a></div><div class="ttdeci">@ notFound</div><div class="ttdef"><b>Definition:</b> <a href="nodestore_2Types_8h_source.html#l00046">nodestore/Types.h:46</a></div></div>
<div class="ttc" id="aclassripple_1_1base__uint_html"><div class="ttname"><a href="classripple_1_1base__uint.html">ripple::base_uint&lt; 256 &gt;</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a3b006f7535475fd276bc30b77a1b4673"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a3b006f7535475fd276bc30b77a1b4673">ripple::NodeStore::DatabaseRotatingImp::getWriteLoad</a></div><div class="ttdeci">std::int32_t getWriteLoad() const override</div><div class="ttdoc">Retrieve the estimated number of pending write operations.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00079">DatabaseRotatingImp.cpp:79</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a3b006f7535475fd276bc30b77a1b4673"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a3b006f7535475fd276bc30b77a1b4673">ripple::NodeStore::DatabaseRotatingImp::getWriteLoad</a></div><div class="ttdeci">std::int32_t getWriteLoad() const override</div><div class="ttdoc">Retrieve the estimated number of pending write operations.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00068">DatabaseRotatingImp.cpp:68</a></div></div>
<div class="ttc" id="aclassripple_1_1Stoppable_html"><div class="ttname"><a href="classripple_1_1Stoppable.html">ripple::Stoppable</a></div><div class="ttdoc">Provides an interface for starting and stopping.</div><div class="ttdef"><b>Definition:</b> <a href="Stoppable_8h_source.html#l00201">Stoppable.h:201</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_af885d9fe877259a258481f0df20697cd"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#af885d9fe877259a258481f0df20697cd">ripple::NodeStore::Database::importInternal</a></div><div class="ttdeci">void importInternal(Backend &amp;dstBackend, Database &amp;srcDB)</div><div class="ttdef"><b>Definition:</b> <a href="Database_8cpp_source.html#l00119">Database.cpp:119</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_af885d9fe877259a258481f0df20697cd"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#af885d9fe877259a258481f0df20697cd">ripple::NodeStore::Database::importInternal</a></div><div class="ttdeci">void importInternal(Backend &amp;dstBackend, Database &amp;srcDB)</div><div class="ttdef"><b>Definition:</b> <a href="Database_8cpp_source.html#l00103">Database.cpp:103</a></div></div>
<div class="ttc" id="anamespaceripple_html_ad99788f1aca6ce31a1fe8365eee1bba3"><div class="ttname"><a href="namespaceripple.html#ad99788f1aca6ce31a1fe8365eee1bba3">ripple::Rethrow</a></div><div class="ttdeci">void Rethrow()</div><div class="ttdoc">Rethrow the exception currently being handled.</div><div class="ttdef"><b>Definition:</b> <a href="contract_8h_source.html#l00048">contract.h:48</a></div></div>
<div class="ttc" id="anamespaceripple_1_1NodeStore_html_a41cef3aa8ed33b8fa1b438ed7b6d1287"><div class="ttname"><a href="namespaceripple_1_1NodeStore.html#a41cef3aa8ed33b8fa1b438ed7b6d1287">ripple::NodeStore::cacheTargetAge</a></div><div class="ttdeci">constexpr std::chrono::seconds cacheTargetAge</div><div class="ttdef"><b>Definition:</b> <a href="nodestore_2impl_2Tuning_8h_source.html#l00036">nodestore/impl/Tuning.h:36</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a4d803c36c8aea67c83f735814de25717"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">ripple::NodeStore::DatabaseRotatingImp::mutex_</a></div><div class="ttdeci">std::mutex mutex_</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8h_source.html#l00114">DatabaseRotatingImp.h:114</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a55502de7f83a364526263b38bc1fe709"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a55502de7f83a364526263b38bc1fe709">ripple::NodeStore::DatabaseRotatingImp::storeLedger</a></div><div class="ttdeci">bool storeLedger(std::shared_ptr&lt; Ledger const &gt; const &amp;srcLedger) override</div><div class="ttdoc">Store a ledger from a different database.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00097">DatabaseRotatingImp.cpp:97</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a4d803c36c8aea67c83f735814de25717"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a4d803c36c8aea67c83f735814de25717">ripple::NodeStore::DatabaseRotatingImp::mutex_</a></div><div class="ttdeci">std::mutex mutex_</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8h_source.html#l00085">DatabaseRotatingImp.h:85</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a55502de7f83a364526263b38bc1fe709"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a55502de7f83a364526263b38bc1fe709">ripple::NodeStore::DatabaseRotatingImp::storeLedger</a></div><div class="ttdeci">bool storeLedger(std::shared_ptr&lt; Ledger const &gt; const &amp;srcLedger) override</div><div class="ttdoc">Store a ledger from a different database.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00086">DatabaseRotatingImp.cpp:86</a></div></div>
<div class="ttc" id="aclassbeast_1_1Journal_html"><div class="ttname"><a href="classbeast_1_1Journal.html">beast::Journal</a></div><div class="ttdoc">A generic endpoint for log messages.</div><div class="ttdef"><b>Definition:</b> <a href="Journal_8h_source.html#l00058">Journal.h:58</a></div></div>
<div class="ttc" id="anamespaceripple_1_1NodeStore_html_af127c2e4fc73b5d35647147ef45b350ca915a2fc67fa0633b4995f8c1e4d54bdf"><div class="ttname"><a href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350ca915a2fc67fa0633b4995f8c1e4d54bdf">ripple::NodeStore::dataCorrupt</a></div><div class="ttdeci">@ dataCorrupt</div><div class="ttdef"><b>Definition:</b> <a href="nodestore_2Types_8h_source.html#l00047">nodestore/Types.h:47</a></div></div>
<div class="ttc" id="ainteger_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/types/integer.html">std::int32_t</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotating_html"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotating.html">ripple::NodeStore::DatabaseRotating</a></div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotating_8h_source.html#l00033">DatabaseRotating.h:33</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Scheduler_html"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Scheduler.html">ripple::NodeStore::Scheduler</a></div><div class="ttdoc">Scheduling for asynchronous backend activity.</div><div class="ttdef"><b>Definition:</b> <a href="ripple_2nodestore_2Scheduler_8h_source.html#l00061">ripple/nodestore/Scheduler.h:61</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_ae018381e1b62ed9c61ef8a82d1b3db47"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ae018381e1b62ed9c61ef8a82d1b3db47">ripple::NodeStore::DatabaseRotatingImp::import</a></div><div class="ttdeci">void import(Database &amp;source) override</div><div class="ttdoc">Import objects from another database.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00086">DatabaseRotatingImp.cpp:86</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a090e39b8c6733b0dc4553f9e8e705605"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a090e39b8c6733b0dc4553f9e8e705605">ripple::NodeStore::Database::storeStats</a></div><div class="ttdeci">void storeStats(std::uint64_t count, std::uint64_t sz)</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00258">Database.h:258</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Scheduler_html"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Scheduler.html">ripple::NodeStore::Scheduler</a></div><div class="ttdoc">Scheduling for asynchronous backend activity.</div><div class="ttdef"><b>Definition:</b> <a href="ripple_2nodestore_2Scheduler_8h_source.html#l00060">ripple/nodestore/Scheduler.h:60</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_ae018381e1b62ed9c61ef8a82d1b3db47"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ae018381e1b62ed9c61ef8a82d1b3db47">ripple::NodeStore::DatabaseRotatingImp::import</a></div><div class="ttdeci">void import(Database &amp;source) override</div><div class="ttdoc">Import objects from another database.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00075">DatabaseRotatingImp.cpp:75</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a090e39b8c6733b0dc4553f9e8e705605"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a090e39b8c6733b0dc4553f9e8e705605">ripple::NodeStore::Database::storeStats</a></div><div class="ttdeci">void storeStats(std::uint64_t count, std::uint64_t sz)</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00245">Database.h:245</a></div></div>
<div class="ttc" id="anamespaceripple_1_1NodeStore_html_af127c2e4fc73b5d35647147ef45b350c"><div class="ttname"><a href="namespaceripple_1_1NodeStore.html#af127c2e4fc73b5d35647147ef45b350c">ripple::NodeStore::Status</a></div><div class="ttdeci">Status</div><div class="ttdoc">Return codes from Backend operations.</div><div class="ttdef"><b>Definition:</b> <a href="nodestore_2Types_8h_source.html#l00044">nodestore/Types.h:44</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a01b2627edcc41e0ea4cd5ac6b0518494"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a01b2627edcc41e0ea4cd5ac6b0518494">ripple::NodeStore::DatabaseRotatingImp::asyncFetch</a></div><div class="ttdeci">bool asyncFetch(uint256 const &amp;hash, std::uint32_t ledgerSeq, std::shared_ptr&lt; NodeObject &gt; &amp;nodeObject) override</div><div class="ttdoc">Fetch an object without waiting.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00128">DatabaseRotatingImp.cpp:128</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="aclassripple_1_1NodeStore_1_1Database_html_aad7aa12d0cc01006120761d23312d428"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#aad7aa12d0cc01006120761d23312d428">ripple::NodeStore::Database::storeLedger</a></div><div class="ttdeci">virtual bool storeLedger(std::shared_ptr&lt; Ledger const &gt; const &amp;srcLedger)=0</div><div class="ttdoc">Store a ledger from a different database.</div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_abff61416b213b5ab28e482a61a9c80f8"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#abff61416b213b5ab28e482a61a9c80f8">ripple::NodeStore::Database::asyncFetch</a></div><div class="ttdeci">virtual bool asyncFetch(uint256 const &amp;hash, std::uint32_t ledgerSeq, std::shared_ptr&lt; NodeObject &gt; &amp;nodeObject)=0</div><div class="ttdoc">Fetch an object without waiting.</div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a7992d0dd009c5b855c331c73872c946d"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a7992d0dd009c5b855c331c73872c946d">ripple::NodeStore::DatabaseRotatingImp::store</a></div><div class="ttdeci">void store(NodeObjectType type, Blob &amp;&amp;data, uint256 const &amp;hash, std::uint32_t) override</div><div class="ttdoc">Store the object.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00108">DatabaseRotatingImp.cpp:108</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a0d7c3d303adce36199b2c67c4df8a2de"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a0d7c3d303adce36199b2c67c4df8a2de">ripple::NodeStore::Database::j_</a></div><div class="ttdeci">const beast::Journal j_</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00247">Database.h:247</a></div></div>
<div class="ttc" id="astructripple_1_1NodeStore_1_1FetchReport_html_a7ab35eb8a30af6dbc6ee916ccf60474d"><div class="ttname"><a href="structripple_1_1NodeStore_1_1FetchReport.html#a7ab35eb8a30af6dbc6ee916ccf60474d">ripple::NodeStore::FetchReport::wasFound</a></div><div class="ttdeci">bool wasFound</div><div class="ttdef"><b>Definition:</b> <a href="ripple_2nodestore_2Scheduler_8h_source.html#l00041">ripple/nodestore/Scheduler.h:41</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a7992d0dd009c5b855c331c73872c946d"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a7992d0dd009c5b855c331c73872c946d">ripple::NodeStore::DatabaseRotatingImp::store</a></div><div class="ttdeci">void store(NodeObjectType type, Blob &amp;&amp;data, uint256 const &amp;hash, std::uint32_t) override</div><div class="ttdoc">Store the object.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00097">DatabaseRotatingImp.cpp:97</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1Database_html_a0d7c3d303adce36199b2c67c4df8a2de"><div class="ttname"><a href="classripple_1_1NodeStore_1_1Database.html#a0d7c3d303adce36199b2c67c4df8a2de">ripple::NodeStore::Database::j_</a></div><div class="ttdeci">const beast::Journal j_</div><div class="ttdef"><b>Definition:</b> <a href="Database_8h_source.html#l00234">Database.h:234</a></div></div>
<div class="ttc" id="astructripple_1_1NodeStore_1_1FetchReport_html_a7ab35eb8a30af6dbc6ee916ccf60474d"><div class="ttname"><a href="structripple_1_1NodeStore_1_1FetchReport.html#a7ab35eb8a30af6dbc6ee916ccf60474d">ripple::NodeStore::FetchReport::wasFound</a></div><div class="ttdeci">bool wasFound</div><div class="ttdef"><b>Definition:</b> <a href="ripple_2nodestore_2Scheduler_8h_source.html#l00040">ripple/nodestore/Scheduler.h:40</a></div></div>
<div class="ttc" id="anamespacestd_html"><div class="ttname"><a href="namespacestd.html">std</a></div><div class="ttdoc">STL namespace.</div></div>
<div class="ttc" id="amake_pair_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/utility/pair/make_pair.html">std::make_pair</a></div><div class="ttdeci">T make_pair(T... args)</div></div>
<div class="ttc" id="aclassripple_1_1NodeObject_html"><div class="ttname"><a href="classripple_1_1NodeObject.html">ripple::NodeObject</a></div><div class="ttdoc">A simple object that the Ledger uses to store entries.</div><div class="ttdef"><b>Definition:</b> <a href="NodeObject_8h_source.html#l00048">NodeObject.h:48</a></div></div>
<div class="ttc" id="aclassripple_1_1KeyCache_html"><div class="ttname"><a href="classripple_1_1KeyCache.html">ripple::KeyCache</a></div><div class="ttdoc">Maintains a cache of keys with no associated data.</div><div class="ttdef"><b>Definition:</b> <a href="KeyCache_8h_source.html#l00043">KeyCache.h:43</a></div></div>
<div class="ttc" id="astructripple_1_1NodeStore_1_1FetchReport_html_a3063c18d4ab5927e8a3cb129745a2ca3"><div class="ttname"><a href="structripple_1_1NodeStore_1_1FetchReport.html#a3063c18d4ab5927e8a3cb129745a2ca3">ripple::NodeStore::FetchReport::wentToDisk</a></div><div class="ttdeci">bool wentToDisk</div><div class="ttdef"><b>Definition:</b> <a href="ripple_2nodestore_2Scheduler_8h_source.html#l00040">ripple/nodestore/Scheduler.h:40</a></div></div>
<div class="ttc" id="aunique_ptr_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/memory/unique_ptr.html">std::unique_ptr</a></div><div class="ttdoc">STL class.</div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_aee99c67c55042890a37368f5d17620d4"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aee99c67c55042890a37368f5d17620d4">ripple::NodeStore::DatabaseRotatingImp::for_each</a></div><div class="ttdeci">void for_each(std::function&lt; void(std::shared_ptr&lt; NodeObject &gt;)&gt; f) override</div><div class="ttdoc">Visit every object in the database This is usually called during import.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00253">DatabaseRotatingImp.cpp:253</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_acaa8e51a8678905a0b2d831154cc91b5"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">ripple::NodeStore::DatabaseRotatingImp::writableBackend_</a></div><div class="ttdeci">std::shared_ptr&lt; Backend &gt; writableBackend_</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8h_source.html#l00112">DatabaseRotatingImp.h:112</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_a679d869332ca5983aeb5f84e5ad710b2"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#a679d869332ca5983aeb5f84e5ad710b2">ripple::NodeStore::DatabaseRotatingImp::nCache_</a></div><div class="ttdeci">std::shared_ptr&lt; KeyCache&lt; uint256 &gt; &gt; nCache_</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8h_source.html#l00110">DatabaseRotatingImp.h:110</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_aee99c67c55042890a37368f5d17620d4"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#aee99c67c55042890a37368f5d17620d4">ripple::NodeStore::DatabaseRotatingImp::for_each</a></div><div class="ttdeci">void for_each(std::function&lt; void(std::shared_ptr&lt; NodeObject &gt;)&gt; f) override</div><div class="ttdoc">Visit every object in the database This is usually called during import.</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8cpp_source.html#l00193">DatabaseRotatingImp.cpp:193</a></div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_acaa8e51a8678905a0b2d831154cc91b5"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#acaa8e51a8678905a0b2d831154cc91b5">ripple::NodeStore::DatabaseRotatingImp::writableBackend_</a></div><div class="ttdeci">std::shared_ptr&lt; Backend &gt; writableBackend_</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8h_source.html#l00083">DatabaseRotatingImp.h:83</a></div></div>
<div class="ttc" id="awhat_html"><div class="ttname"><a href="http://en.cppreference.com/w/cpp/error/exception/what.html">std::exception::what</a></div><div class="ttdeci">T what(T... args)</div></div>
<div class="ttc" id="aclassripple_1_1NodeStore_1_1DatabaseRotatingImp_html_ad8ffa795b9c94db42da3548719e3d125"><div class="ttname"><a href="classripple_1_1NodeStore_1_1DatabaseRotatingImp.html#ad8ffa795b9c94db42da3548719e3d125">ripple::NodeStore::DatabaseRotatingImp::pCache_</a></div><div class="ttdeci">std::shared_ptr&lt; TaggedCache&lt; uint256, NodeObject &gt; &gt; pCache_</div><div class="ttdef"><b>Definition:</b> <a href="DatabaseRotatingImp_8h_source.html#l00107">DatabaseRotatingImp.h:107</a></div></div>
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">