fleet
fleet
¶
Fleet management for the Marianne conductor.
A fleet is a concert-of-concerts: multiple agent scores launched and managed as a unit. The FleetManager handles fleet-level lifecycle operations: detection, group dependency resolution, concurrent score launch, and fleet-level pause/resume/cancel.
Fleets are one level of nesting: fleet → score → sheet. No fleet-of-fleets.
Classes¶
FleetRecord
¶
Tracks a running fleet's state.
Stores the mapping from fleet_id → member job_ids, group assignments, and dependency ordering for fleet-level operations.
Source code in src/marianne/daemon/fleet.py
Functions¶
is_fleet_config
¶
Check if a YAML file is a fleet config (type: fleet).
Quick check that reads the YAML without full validation. Returns False on any error rather than raising.
Source code in src/marianne/daemon/fleet.py
topological_sort_groups
¶
Sort fleet groups into dependency layers.
Returns a list of sets, where each set contains group names that can run concurrently. Earlier sets must complete before later sets start.
Groups not declared in the groups dict are treated as having no dependencies and are placed in the first layer.
Source code in src/marianne/daemon/fleet.py
submit_fleet
async
¶
Submit a fleet config — launch scores in group-dependency order.
Launches all scores in each group layer concurrently, waiting for each layer to be submitted before proceeding to the next.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
manager
|
JobManager
|
The JobManager to submit individual scores through. |
required |
config_path
|
Path
|
Path to the fleet YAML file (for relative path resolution). |
required |
fleet_config
|
FleetConfig
|
Parsed fleet configuration. |
required |
Returns:
| Type | Description |
|---|---|
JobResponse
|
JobResponse with fleet_id and status. |
Source code in src/marianne/daemon/fleet.py
115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 | |
pause_fleet
async
¶
Pause all member scores in a fleet.
Source code in src/marianne/daemon/fleet.py
resume_fleet
async
¶
Resume all paused member scores in a fleet.
Source code in src/marianne/daemon/fleet.py
cancel_fleet
async
¶
Cancel all member scores in a fleet.
Source code in src/marianne/daemon/fleet.py
get_fleet_status
¶
Get status of a fleet and all its member scores.