<ulclass="index"><li><ahref="#description">Description</a></li><li><ahref="#index">Function Index</a></li><li><ahref="#functions">Function Details</a></li></ul>Erlang API for the Machi client-implemented Chain Replication
<p>The major operation processing is implemented in a state machine-like
manner. Before attempting an operation <code>X</code>, there's an initial
operation <code>pre-X</code> that takes care of updating the epoch id,
restarting client protocol proxies, and if there's any server
instability (e.g. some server is wedged), then insert some sleep
time. When the chain appears to have stabilized, then we try the <code>X</code>
operation again.</p>
<p>Function name for the <code>pre-X</code> stuff is usually <code>X()</code>, and the
function name for the <code>X</code> stuff is usually <code>X2()</code>. (I.e., the <code>X</code>
stuff follows after <code>pre-X</code> and therefore has a <code>2</code> suffix on the
function name.)</p>
In the case of read repair, there are two stages: find the value to
perform the repair, then perform the repair writes. In the case of
the repair writes, the <code>pre-X</code> function is named <code>read_repair3()</code>,
and the <code>X</code> function is named <code>read_repair4()</code>.
<h2><aname="index">Function Index</a></h2>
<tablewidth="100%"border="1"cellspacing="0"cellpadding="2"summary="function index"><tr><tdvalign="top"><ahref="#append_chunk-3">append_chunk/3</a></td><td>Append a chunk (binary- or iolist-style) of data to a file
with <code>Prefix</code>.</td></tr>
<tr><tdvalign="top"><ahref="#append_chunk-4">append_chunk/4</a></td><td>Append a chunk (binary- or iolist-style) of data to a file
with <code>Prefix</code>.</td></tr>
<tr><tdvalign="top"><ahref="#append_chunk_extra-4">append_chunk_extra/4</a></td><td>Append a chunk (binary- or iolist-style) of data to a file
with <code>Prefix</code>.</td></tr>
<tr><tdvalign="top"><ahref="#append_chunk_extra-5">append_chunk_extra/5</a></td><td>Append a chunk (binary- or iolist-style) of data to a file
with <code>Prefix</code>.</td></tr>
<tr><tdvalign="top"><ahref="#checksum_list-2">checksum_list/2</a></td><td>Fetch the list of chunk checksums for <code>File</code>.</td></tr>
<tr><tdvalign="top"><ahref="#checksum_list-3">checksum_list/3</a></td><td>Fetch the list of chunk checksums for <code>File</code>.</td></tr>
<tr><tdvalign="top"><ahref="#read_chunk-4">read_chunk/4</a></td><td>Read a chunk of data of size <code>Size</code> from <code>File</code> at <code>Offset</code>.</td></tr>
<tr><tdvalign="top"><ahref="#read_chunk-5">read_chunk/5</a></td><td>Read a chunk of data of size <code>Size</code> from <code>File</code> at <code>Offset</code>.</td></tr>
<tr><tdvalign="top"><ahref="#start_link-1">start_link/1</a></td><td>Start a local, long-lived process that will be our steady
& reliable communication proxy with the fickle & flaky
<tr><tdvalign="top"><ahref="#write_chunk-4">write_chunk/4</a></td><td>Write a chunk of data (that has already been
allocated/sequenced by an earlier append_chunk_extra() call) to
<code>File</code> at <code>Offset</code>.</td></tr>
<tr><tdvalign="top"><ahref="#write_chunk-5">write_chunk/5</a></td><td>Read a chunk of data of size <code>Size</code> from <code>File</code> at <code>Offset</code>.</td></tr>