Commit 515b701
authored
[rust/scheduler] Distributed Scheduler (#2104)
This PR introduces a new module called "scheduler." This module is
responsible for the booking aspect of Cuebot and is designed to offload
this feature from the central module.
Rationale: Cuebot's booking logic depends on responding to each
HostReport with a new task that searches for layers to dispatch to the
reporting host. Consequently, each request generates a
[BookingQuery](https://github.com/AcademySoftwareFoundation/OpenCue/blob/master/cuebot/src/main/java/com/imageworks/spcue/dao/postgres/DispatchQuery.java),
which significantly impacts the database. As a result, scaling Cuebot is
limited by the need to optimize database capacity to handle complex
queries. This new module alleviates the booking workload from Cuebot.
Booking on the Scheduler is not triggered by host reports; instead, it
operates through an internal loop that searches for pending jobs and
seeks suitable matches from a cached view of the hosts in the database.
The scheduler organizes layers and hosts into clusters, with each
cluster representing a group of show and allocation combinations. This
structure allows multiple instances of the scheduler to share the load
without competing for work, which is a significant issue in Cuebot.
To enable Cuebot and the Scheduler to run concurrently without competing
for work, a new feature was added to Cuebot, as detailed in
#2087. This
feature allows for the addition of an exclusion list containing show and
allocations that should not be booked, or it can halt booking for all
shows altogether.
---------
Signed-off-by: Diego Tavares <dtavares@imageworks.com>1 parent 5b8b02d commit 515b701
58 files changed
Lines changed: 17457 additions & 33 deletions
File tree
- rust
- config
- crates
- dummy-cuebot
- rqd
- resources/test_scripts
- src/system
- scheduler
- resources
- src
- config
- dao
- host_cache
- metrics
- models
- pipeline
- dispatcher
- tests
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
| 31 | + | |
30 | 32 | | |
31 | 33 | | |
32 | 34 | | |
33 | 35 | | |
34 | 36 | | |
35 | 37 | | |
36 | 38 | | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
7 | 6 | | |
8 | 7 | | |
9 | 8 | | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
0 commit comments