Skip to content

Admin Tools API

This page documents the arcticdb.version_store.admin_tools module. This exposes administrative functionality aimed at power users and DBAs.

These tools are intended for adhoc use. The API is not currently stable and not governed by the semver version numbers of ArcticDB releases.

To get an arcticdb.version_store.admin_tools.AdminTools instance, use arcticdb.version_store.Library.get_admin_tools.

arcticdb.version_store.admin_tools.Size dataclass

Information about the size of objects.

ATTRIBUTE DESCRIPTION
bytes_compressed

Compressed size in bytes.

TYPE: int

count

The number of objects contributing to the size.

TYPE: int

bytes_compressed instance-attribute

bytes_compressed: int

Compressed size in bytes.

count instance-attribute

count: int

The number of objects contributing to the size.

arcticdb.version_store.admin_tools.KeyType

Bases: Enum

This is a subset of all the key types that ArcticDB uses, covering the most important types.

More information about the ArcticDB data layout is available here.

ATTRIBUTE DESCRIPTION
APPEND_DATA

Only used for staged writes. Data that has been staged but not yet finalized.

LOG

Only used for enterprise replication. Small objects recording a stream of changes to the library.

LOG_COMPACTED

Only used for some enterprise replication installations. A compacted form of the LOG keys.

MULTI_KEY

Only used for "recursively normalized" data, which cannot currently be written with the Library API.

SNAPSHOT_REF

Metadata used by ArcticDB to store the contents of a snapshot (the structure created when you call lib.snapshot).

SYMBOL_LIST

A collection of keys that together store the total set of symbols stored in a library. Used for list_symbols.

TABLE_DATA

Where the contents of data are stored, in a tiled format.

TABLE_INDEX

Metadata used by ArcticDB to select the TABLE_DATA blocks to read. One per un-deleted version of the symbol.

VERSION

Metadata used by ArcticDB to store the chain of versions associated with a symbol. It is possible to have

VERSION_REF

A pointer to the latest version of a symbol. One per symbol.

APPEND_DATA class-attribute instance-attribute

APPEND_DATA = 5

Only used for staged writes. Data that has been staged but not yet finalized.

LOG class-attribute instance-attribute

LOG = 8

Only used for enterprise replication. Small objects recording a stream of changes to the library.

LOG_COMPACTED class-attribute instance-attribute

LOG_COMPACTED = 9

Only used for some enterprise replication installations. A compacted form of the LOG keys.

MULTI_KEY class-attribute instance-attribute

MULTI_KEY = 6

Only used for "recursively normalized" data, which cannot currently be written with the Library API.

Records all the TABLE_INDEX keys used to compose the overall structure. For example, if you save a list of two dataframes with recursive normalizers, this key would refer to the two index keys used to serialize the two dataframes.

SNAPSHOT_REF class-attribute instance-attribute

SNAPSHOT_REF = 7

Metadata used by ArcticDB to store the contents of a snapshot (the structure created when you call lib.snapshot).

SYMBOL_LIST class-attribute instance-attribute

SYMBOL_LIST = 10

A collection of keys that together store the total set of symbols stored in a library. Used for list_symbols.

TABLE_DATA class-attribute instance-attribute

TABLE_DATA = 1

Where the contents of data are stored, in a tiled format.

TABLE_INDEX class-attribute instance-attribute

TABLE_INDEX = 2

Metadata used by ArcticDB to select the TABLE_DATA blocks to read. One per un-deleted version of the symbol.

VERSION class-attribute instance-attribute

VERSION = 3

Metadata used by ArcticDB to store the chain of versions associated with a symbol. It is possible to have more VERSION keys than the version number of a symbol, as we also write a VERSION key when we delete data.

VERSION_REF class-attribute instance-attribute

VERSION_REF = 4

A pointer to the latest version of a symbol. One per symbol.

arcticdb.version_store.admin_tools.AdminTools

A collection of tools for administrative tasks on an ArcticDB library.

This API is not currently stable and not governed by the semver version numbers of ArcticDB releases.

See Also

Library.admin_tools: The API to get a handle on this object from a Library.

METHOD DESCRIPTION
get_sizes

A breakdown of compressed sizes (in bytes) in the library, grouped by key type.

get_sizes_by_symbol

A breakdown of compressed sizes (in bytes) in the library, grouped by symbol and then key type.

get_sizes_for_symbol

A breakdown of compressed sizes (in bytes) used by the given symbol, grouped by key type.

get_sizes

get_sizes() -> Dict[KeyType, Size]

A breakdown of compressed sizes (in bytes) in the library, grouped by key type.

All the key types in KeyType are always included in the output.

get_sizes_by_symbol

get_sizes_by_symbol() -> Dict[str, Dict[KeyType, Size]]

A breakdown of compressed sizes (in bytes) in the library, grouped by symbol and then key type.

The following key types (and only these) are always included in the output,

VERSION_REF
VERSION
TABLE_INDEX
TABLE_DATA
APPEND_DATA

get_sizes_for_symbol

get_sizes_for_symbol(symbol: str) -> Dict[KeyType, Size]

A breakdown of compressed sizes (in bytes) used by the given symbol, grouped by key type.

The following key types (and only these) are always included in the output:

VERSION_REF
VERSION
TABLE_INDEX
TABLE_DATA
APPEND_DATA

Does not raise if the symbol does not exist.