Scheduling and remote execution
Built: steps run on the local machine only. One module both schedules and runs. The steps of every job are scheduled as one graph, up to -j at once and within the resource pools, and every step is measured. See How steps are run.
A scheduler and an executor
Two parts with a narrow boundary between them:
- Scheduler: walks the step graph, checks the cache, and hands ready steps to an executor. It enforces the step limit and the resource pools, as it does today.
- Executor: runs one step and returns its exit status, logs and output paths. The local executor runs processes, streams logs to files and the terminal, and kills the process group on cancel.
What this adds to the code as it is:
- The boundary itself. Today the code that walks the graph also starts the processes, and nothing calls through a trait.
- Enforcing what a step holds on a remote machine, where locally it is enforced with cgroups (see Enforcing resources).
- Logs on the terminal as well as in files.
- An async runtime, in place of a thread per running step.
Launchers only see steps. No launcher knows a tool, and one scheduler serves them all.
Sharing licences between runs
Resource pools are counted within one run. Two runs at once, in one checkout or in two, or on two hosts, each start up to their own pool sizes, so together they can ask the licence server for more than the site has. Xcelium and IMC wait in the server’s queue when that happens (-licqueue), so nothing fails, but the waiting is not visible to doris and a step’s measured time includes it.
What is needed is a pool that several processes and hosts count against together: a pool server, a lock directory on a shared filesystem with one file per licence, or the licence server’s own count. Until then, give each run a share with --set pools.NAME=N.
Remote execution
Because steps declare their inputs and outputs, a remote executor can stage files in and out, as Bazel’s remote execution API does. Schedulers such as LSF or Slurm can be added the same way, using a shared filesystem instead of staging. Nothing is built for remote execution beyond keeping steps self-describing.
Other platforms
doris is Linux only, and no other platform is planned.