Skip to main content

Module io

Module io 

Source
Expand description

Object store access for WAL objects: a deterministic key layout and conditional creates that make a retry of the same object a no-op.

Structsยง

ListedObject ๐Ÿ”’
An object discovered by a LIST.
ObjectStoreIo ๐Ÿ”’
Reads and writes the WAL objects under one prefix.

Enumsยง

PutResult ๐Ÿ”’
Outcome of a conditional create.

Constantsยง

LISTING_AHEAD_OBJECTS ๐Ÿ”’
Objects a listing may hold ahead of the reads that take them, four LIST pages of S3, so the listing stays pages ahead of the reads while what it holds is bounded.
OBJECT_SEQ_WIDTH ๐Ÿ”’
Width of the zero-padded object sequence in an object key, wide enough for u64::MAX so that lexicographic and numeric order agree.
OBJECT_SUFFIX ๐Ÿ”’
PROBE_CONTENT ๐Ÿ”’

Functionsยง

normalize_prefix ๐Ÿ”’
reports_existing_object ๐Ÿ”’
Returns true when a conditional create failed because the object exists. Only the precondition failure says so: a store may report AlreadyExists for an unrelated path, such as a parent that is a file.
settle_listing ๐Ÿ”’
Yields the objects listing sends over rx. Once the listing finished it is settled before any further object is yielded, so its failure goes before the objects it listed that the caller has not taken yet.