Interfaces
Interfaces of tasks that can be executed in parallel or sequentially.
amsdal_glue.interfaces.SequentialExecutor ¶
Bases: ABC
Interface for sequential executor.
execute_sequential
abstractmethod
¶
execute_sequential(
tasks, final_task, transaction_id, lock_id
)
Executes the given tasks sequentially.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
tasks
|
list[Task]
|
The list of tasks to be executed. |
required |
final_task
|
Task | None
|
The final task to be executed. |
required |
transaction_id
|
str | None
|
The transaction ID to be used during execution. |
required |
lock_id
|
str | None
|
The lock ID to be used during execution. |
required |
Returns:
Name | Type | Description |
---|---|---|
Any |
Any
|
The result of the execution. |
amsdal_glue.interfaces.ParallelExecutor ¶
Bases: ABC
Interface for parallel executor.
Methods:
Name | Description |
---|---|
execute_parallel |
list[Task], transaction_id: str | None, lock_id: str | None) -> Any: Executes the given tasks in parallel. |
execute_parallel
abstractmethod
¶
execute_parallel(tasks, transaction_id, lock_id)
Executes the given tasks in parallel.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
tasks
|
list[Task]
|
The list of tasks to be executed. |
required |
transaction_id
|
str | None
|
The transaction ID to be used during execution. |
required |
lock_id
|
str | None
|
The lock ID to be used during execution. |
required |
Returns:
Name | Type | Description |
---|---|---|
Any |
Any
|
The result of the execution. |
amsdal_glue.interfaces.FinalDataQueryExecutor ¶
Bases: ABC
Interface for final data query executor.
Methods:
Name | Description |
---|---|
execute |
FinalDataQueryNode, transaction_id: str | None, lock_id: str | None) -> None: Executes the given final data query node. |
execute
abstractmethod
¶
execute(query_node, transaction_id, lock_id)
Executes the given final data query node.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
query_node
|
FinalDataQueryNode
|
The final data query node to be executed. |
required |
transaction_id
|
str | None
|
The transaction ID to be used during execution. |
required |
lock_id
|
str | None
|
The lock ID to be used during execution. |
required |