Commit a5828a2
perf(cli): parallelize scenario log downloads with max concurrency of 50 (#176)
## Summary
- Replace the serial download loop in `rli bmj logs` with a concurrent
executor capped at 50 simultaneous downloads
- Adds a small `runWithConcurrency` helper that distributes tasks across
N workers using a shared index
- Output lines are printed atomically per-download (one full line with ✓
on success) since the old "write prefix / complete line" pattern doesn't
work in parallel
## Test plan
- [ ] Run `rli bmj logs <job-id>` on a job with many scenarios and
confirm downloads complete much faster
- [ ] Verify the output directory structure matches the previous
behaviour (`<output-dir>/<agent>/<scenario>/`)
- [ ] Verify `results.json` is written correctly for each scenario
- [ ] Confirm failed downloads still produce warning messages and the
final summary counts correctly
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Runloop Agent <[email protected]>
Co-authored-by: Claude Sonnet 4.6 <[email protected]>1 parent 23f8a28 commit a5828a2
1 file changed
+36
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
253 | 253 | | |
254 | 254 | | |
255 | 255 | | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
256 | 279 | | |
257 | 280 | | |
258 | 281 | | |
| |||
326 | 349 | | |
327 | 350 | | |
328 | 351 | | |
329 | | - | |
| 352 | + | |
| 353 | + | |
330 | 354 | | |
331 | | - | |
332 | | - | |
333 | | - | |
334 | | - | |
| 355 | + | |
| 356 | + | |
335 | 357 | | |
336 | 358 | | |
337 | | - | |
338 | | - | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
339 | 363 | | |
340 | | - | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
341 | 369 | | |
342 | 370 | | |
343 | 371 | | |
| |||
0 commit comments