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
class Database(BaseEntity): (source)
Represent the configuration entity for a database-backed job store.
Mirrors APScheduler's SQLAlchemy job store configuration, allowing a dedicated connection/table to persist scheduled task definitions.
| Method | __post |
Validate the Database job store configuration after initialization. |
| Method | __validate |
Validate the connection property. |
| Method | __validate |
Validate the driver property. |
| Method | __validate |
Validate the table property. |
| Instance Variable | connection |
The database connection name used to store scheduled tasks. Resolved from the DB_TASK_CONNECTION environment variable or None to use the application's default connection. |
| Instance Variable | driver |
The driver type. Defaults to 'database'. |
| Instance Variable | table |
The database table name used to store scheduled tasks. Must match the pattern [a-z_]+. Resolved from the DB_TASK_TABLE environment variable or defaults to 'scheduler_tasks'. |
Inherited from BaseEntity:
| Class Method | _cached |
Retrieve field definitions and normalized types cached by class. |
| Method | get |
Describe field names, normalized types, defaults, and metadata. |
| Method | to |
Convert the dataclass instance to a recursively copied dictionary. |
| Class Variable | __slots__ |
Undocumented |
Validate the Database job store configuration after initialization.
| Returns | |
None | Validates every field against its declared type hint. |
| Raises | |
TypeError | If any property does not match its expected type. |
ValueError | If table fails table-name validation. |
Validate the driver property.
| Returns | |
None | This method performs validation and returns None. |
| Raises | |
TypeError | If driver is not a string. |
ValueError | If driver is an empty string. |
Validate the table property.
| Returns | |
None | This method performs validation and returns None. |
| Raises | |
TypeError | If table is not a string. |
ValueError | If table does not match the required pattern. |