Skip to content

Implement AsynchronousComputeService with reactive scheduling #432

Description

@dotsdl

Up to now, we have been making use of the SynchronousComputeService as our workhorse for executing alchemical Transformations at scale. This service executes a ProtocolDAG one ProtocolUnit at a time, currently in-process, and by virtue of its simplicity it is also very robust.

However, a downside to this service is that it can leave a lot of potential throughput on the table. For example, if the service is provisioned with a GPU, running one ProtocolUnit at a time may not come anywhere close to saturating it. Running more than one ProtocolUnit in parallel on the GPU may yield substantially more throughput if there is capacity for it.

We propose creating an AsynchronousComputeService that is capable of performing one or Tasks/ProtocolDAGs concurrently, with multiple ProtocolUnits executed in parallel. Because there isn't a reliable way to predict how much a given ProtocolUnit may saturate the compute service's resources (CPU, memory, GPU load, GPU memory), we also propose that this service perform reactive scheduling:

  • if its resources aren't yet saturated, it will attempt to run an additional ProtocolUnit in parallel with those already running.
  • if its resources are oversaturated, it will kill the most recently started ProtocolUnit it is running in parallel, and not attempt to run it again until conditions change.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status
Upcoming Sprint - Queued

Relationships

None yet

Development

No branches or pull requests

Issue actions