orangeqs.juice.task_manager._schemas#

Module Contents#

Classes#

TaskEvent

Model for a task event from client.

IPythonServiceState

Model for a IPython service state event.

API#

class orangeqs.juice.task_manager._schemas.TaskEvent(/, **data: Any)#

Bases: orangeqs.juice.messaging.Event

Model for a task event from client.

Model that represents a task event sent from a client to the task manager. This model is used to write the task to the database. And also publish it to subscribers.

measurement: ClassVar[str]#

‘task_event’

task_id: str#

None

The unique identifier of the task.

task_target: str#

None

The target service of the task.

task_type: str#

None

The type of the task.

task_display_name: str#

None

The display name of the task.

task_metadata: str#

None

Metadata associated with the task.

This field contains a JSON-serialized string representing the metadata dictionary for the task.

task_payload: str#

None

The payload of the task.

This field contains a JSON-serialized string representing the payload dictionary for the task.

task_state: Annotated[Literal[created, started, completed, failed], tag]#

None

The current status of the task.

show_in_dashboard: bool#

True

Whether this task is shown in the dashboard by default.

class orangeqs.juice.task_manager._schemas.IPythonServiceState(/, **data: Any)#

Bases: orangeqs.juice.messaging.Event

Model for a IPython service state event.

Model that represents the state of a service. This model is used to write the service state to the database and also publish it to subscribers.

topic() str#

Return the topic for event.

measurement: ClassVar[str]#

‘service_state’

service: Annotated[str, tag]#

None

The name of the service.

state: Literal[idle, busy, restarting, connecting, unknown]#

None

The current state of the service.