C · Errors

Errors

#include <ustore/types.h> 1.0.0-rc.1 · d6d40961

API

Types

ustore_status_tWhat went wrong, in one vocabulary shared by every engine and binding.
types.h:288 ↗
enum ustore_status_t

Shared statuses carry USearch's numbers, leaving 3, 4, 5, 11 and 13 unused, and UStore's own start at 18. Statuses fall into five categories: resources, input, state, interruptions and defects. Any verb that allocates, binds a device or touches a file may also return a resources status; any verb taking a progress callback may return an interruption. A verb's own block lists only what its contract adds.

Values

ustore_status_success_k0The call succeeded; message carries nothing.
ustore_status_deferred_k1A deferred call that has not finished; the one status that is never final.
ustore_status_out_of_memory_k2An allocation could not be satisfied.
ustore_status_read_only_k6The call would change a database opened read-only, as ustore_database_view_rocksdb opens one.
ustore_status_io_k7A file or directory could not be opened, read, written, or closed.
ustore_status_device_k8A device could not be selected, or its memory could not be claimed, or the call's executor, database and arena belong to different residencies or devices.
ustore_status_malformed_k9Stored or supplied data could not be decoded, like a corrupted file, an invalid document, or raw NVMe data directories listed in another order than the database was created with.
ustore_status_internal_k10The engine failed in a way no other status names, which points at a defect.
ustore_status_uninitialized_k12The call needs a database or transaction that was never opened.
ustore_status_contended_k14The call was refused rather than waited for: its executor's deferred table is full, its arena or its transaction serves another call, or it drains or blocks from a callback its own executor runs.
ustore_status_cancelled_k15A progress callback stopped the call, which unwound and published nothing.
ustore_status_unsupported_k16The engine or build does not implement what the call asks for, like io_uring on a kernel without it.
ustore_status_invalid_argument_k17An argument is null, contradicts another one, or carries a choice the call does not accept, like a collection of another modality, a name reserved for a system collection, or a batch of strings in an unknown layout.
ustore_status_not_found_k18A collection, a directory, or a document a modification needs does not exist, while a read marks a missing key with an unset presence bit instead.
ustore_status_already_exists_k19A collection name or a document the call creates is already taken, or the first slot of a raw medium an NVMe database opens belongs to something else.
ustore_status_write_conflict_k20A concurrent writer changed a key this transaction wrote; retry the transaction.
ustore_status_read_conflict_k21A concurrent writer changed a key this transaction read; retry the transaction.
ustore_status_phantom_conflict_k22A concurrent writer inserted into a range this transaction scanned; retry the transaction.
ustore_status_capacity_exhausted_k23A hard design ceiling was reached.

Spellings

char const * ustore_status_name(ustore_status_t status);
ustore_status_t ustore_status_from_name(ustore_bytes_view_t name);