<appendix xmlns="http://docbook.org/ns/docbook" version="5.0"
      xmlns:xlink="http://www.w3.org/1999/xlink"
      xml:id="errcode">

<title>List of error codes</title>

<para>In the current version of the binary protocol, error message,
which is normally more descriptive than error code,
is not present in server response. The actual message may contain
a file name, a detailed reason or an operating system error code.
All such messages, however, are logged in the error log. When
using <emphasis role="strong">Memcached</emphasis> protocol, the error message is sent to the
client along with the code. Below follow only general descriptions
of some popular codes. A complete list of errors can be found in
file <filename xlink:href="https://github.com/tarantool/tarantool/blob/master/include/errcode.h">errcode.h</filename> in the source tree.

</para>
<variablelist>
<title>List of error codes</title>

  <varlistentry>
    <term xml:id="ER_NONMASTER" xreflabel="ER_NONMASTER">ER_NONMASTER</term>
    <listitem><para>Attempt to execute an update on a running
    replica.
    </para></listitem>
  </varlistentry>

  <varlistentry>
    <term xml:id="ER_ILLEGAL_PARAMS" xreflabel="ER_ILLEGAL_PARAMS">ER_ILLEGAL_PARAMS</term>
    <listitem><para>Illegal parameters. Malformed protocol
    message.
    </para></listitem>
  </varlistentry>

  <varlistentry>
    <term xml:id="ER_MEMORY_ISSUE" xreflabel="ER_MEMORY_ISSUE">ER_MEMORY_ISSUE</term>
    <listitem><para>Out of memory: <olink targetptr="slab_alloc_arena"/> limit is reached.
    </para></listitem>
  </varlistentry>

  <varlistentry>
    <term xml:id="ER_WAL_IO" xreflabel="ER_WAL_IO">ER_WAL_IO</term>
    <listitem><para>Failed to record the change in the write ahead
    log. Some sort of disk error.
    </para></listitem>
  </varlistentry>

  <varlistentry>
    <term xml:id="ER_KEY_PART_COUNT" xreflabel="ER_KEY_PART_COUNT">ER_KEY_PART_COUNT</term>
    <listitem><para>Key part count is greater than index part count
    </para></listitem>
  </varlistentry>

  <varlistentry>
    <term xml:id="ER_NO_SUCH_SPACE" xreflabel="ER_NO_SUCH_SPACE">ER_NO_SUCH_SPACE</term>
    <listitem><para>Attempt to access a space that is not
    configured (doesn't exist).
    </para></listitem>
  </varlistentry>

  <varlistentry>
    <term xml:id="ER_NO_SUCH_INDEX" xreflabel="ER_NO_SUCH_INDEX">ER_NO_SUCH_INDEX</term>
    <listitem><para>No index with the given id exists.
    </para></listitem>
  </varlistentry>

  <varlistentry>
    <term xml:id="ER_PROC_LUA" xreflabel="ER_PROC_LUA">ER_PROC_LUA</term>
    <listitem><para>An error inside Lua procedure.
    </para></listitem>
  </varlistentry>

  <varlistentry>
    <term xml:id="ER_FIBER_STACK" xreflabel="ER_FIBER_STACK">ER_FIBER_STACK</term>
    <listitem><para>Recursion limit reached when creating a new fiber. This is
    usually an indicator of a bug in a stored procedure, recursively invoking itself
    ad infinitum.
    </para></listitem>
  </varlistentry>

  <varlistentry>
    <term xml:id="ER_UPDATE_FIELD" xreflabel="ER_UPDATE_FIELD">ER_UPDATE_FIELD</term>
    <listitem><para>A error occured during update of a field.
    </para></listitem>
  </varlistentry>

</variablelist>
</appendix>

<!--
vim: tw=66 syntax=docbk
vim: spell spelllang=en_us
-->
