ORIONIS API REFERENCE

THE ORIONIS API

Build with clarity.

Explore the building blocks of an async-first Python framework. Every module, class, and method — connected, searchable, and ready to build with.

class documentation

Represent the configuration entity for a database-backed cache store.

Mirrors database cache store configuration array, supporting a dedicated connection/table for cache entries and an independent connection/table for the atomic locks used by Cache::lock().

Method __post_init__ Validate the Database cache configuration after initialization.
Method __validateConnection Validate the connection property.
Method __validateDriver Validate the driver property.
Method __validateLockTable Validate the lock_table property.
Method __validateTable Validate the table property.
Instance Variable connection The database connection name used to store cache entries. Resolved from the DB_CACHE_CONNECTION environment variable or None to use the application's default connection.
Instance Variable driver The driver type. Defaults to 'database'.
Instance Variable lock_table The database table name used to store cache locks. Must match the pattern [a-z_]+ when provided. Resolved from the DB_CACHE_LOCK_TABLE environment variable or None to let the driver fall back to its own default.
Instance Variable table The database table name used to store cache entries. Must match the pattern [a-z_]+. Resolved from the DB_CACHE_TABLE environment variable or defaults to 'cache'.

Inherited from BaseEntity:

Class Method _cachedFieldMetadata Retrieve field definitions and normalized types cached by class.
Method getFields Describe field names, normalized types, defaults, and metadata.
Method toDict Convert the dataclass instance to a recursively copied dictionary.
Class Variable __slots__ Undocumented
def __post_init__(self): (source)

Validate the Database cache configuration after initialization.

Returns
NoneValidates every field against its declared type hint.
Raises
TypeErrorIf any property does not match its expected type.
ValueErrorIf table or lock_table fail table-name validation.
def __validateConnection(self): (source)

Validate the connection property.

Returns
NoneThis method performs validation and returns None.
Raises
TypeErrorIf connection is neither a string nor None.
def __validateDriver(self): (source)

Validate the driver property.

Returns
NoneThis method performs validation and returns None.
Raises
TypeErrorIf driver is not a string.
ValueErrorIf driver is an empty string.
def __validateLockTable(self): (source)

Validate the lock_table property.

Returns
NoneThis method performs validation and returns None.
Raises
TypeErrorIf lock_table is neither a string nor None.
ValueErrorIf lock_table is provided but does not match the required pattern.
def __validateTable(self): (source)

Validate the table property.

Returns
NoneThis method performs validation and returns None.
Raises
TypeErrorIf table is not a string.
ValueErrorIf table does not match the required pattern.
connection: str | None = (source)

The database connection name used to store cache entries. Resolved from the DB_CACHE_CONNECTION environment variable or None to use the application's default connection.

The driver type. Defaults to 'database'.

lock_table: str | None = (source)

The database table name used to store cache locks. Must match the pattern [a-z_]+ when provided. Resolved from the DB_CACHE_LOCK_TABLE environment variable or None to let the driver fall back to its own default.

The database table name used to store cache entries. Must match the pattern [a-z_]+. Resolved from the DB_CACHE_TABLE environment variable or defaults to 'cache'.