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

class ScheduleWorkCommand(BaseCommand): (source)

View In Hierarchy

Register and run the application's scheduled tasks.

Method __registerListeners Register the application's available scheduler event callbacks.
Async Method __shutdownSchedule Request graceful shutdown and wait until it completes.
Method __startPanel Display a formatted scheduler start message on the console.
Async Method handle Run the application's scheduled tasks worker.
Class Variable description Command description.
Class Variable signature Command signature and description.
Class Variable timestamps Indicates whether timestamps will be shown in the command output.
def __registerListeners(self, scheduler: object, schedule_service: ISchedule): (source)

Register the application's available scheduler event callbacks.

Parameters
scheduler:objectApplication scheduler that may define event callbacks.
schedule_service:orionis.console.contracts.IScheduleSchedule service receiving the callbacks.
Returns
NoneThe callbacks are registered on the schedule service.
async def __shutdownSchedule(self, schedule_service: ISchedule): (source)

Request graceful shutdown and wait until it completes.

Parameters
schedule_service:orionis.console.contracts.IScheduleScheduler service to shut down.
Returns
NoneThe scheduler service has completed its shutdown sequence.
def __startPanel(self, console: Console): (source)

Display a formatted scheduler start message on the console.

Parameters
console:orionis.console.ConsoleRich console used to display the startup message.
Returns
NoneThe startup information is printed to the console.
async def handle(self, app: IApplication, console: Console) -> int | None: (source)

Run the application's scheduled tasks worker.

Parameters
app:orionis.IApplicationApplication instance for configuration and service resolution.
console:orionis.console.ConsoleRich console used to display scheduler startup information.
Returns
int | NoneOne when the configured backend is unavailable, otherwise None.
description: str = (source)

Command description.

signature: str = (source)

Command signature and description.

timestamps: bool = (source)

Indicates whether timestamps will be shown in the command output.