Commit 227d0fd
perf(cli): parallelize scenario run fetching and name resolution in bmj logs (#179)
## Summary
- Replace the serial per-agent loop in \`downloadBenchmarkJobLogs\` with
\`Promise.allSettled\`, so all agents' \`listBenchmarkRunScenarioRuns\`
calls run concurrently
- Replace serial \`resolveScenarioName\` calls with a single
\`Promise.all\` batch across all scenario runs
The log downloads were already parallelized (max concurrency 50). This
PR fixes the loading/setup phase which was the remaining serial
bottleneck.
**Before**: loading time = sum of all agents' fetch times + sum of all
scenario name lookups
**After**: loading time ~= slowest single agent fetch + slowest single
name lookup
## Test plan
- [ ] Run \`rli bmj logs <job-id>\` with a multi-agent benchmark job and
verify logs download correctly
- [ ] Verify agent fetch failures surface as warnings (not crashes) via
the \`allSettled\` error handling
- [ ] Verify \`--run\` and \`--scenario\` filters still work correctly
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Runloop Agent <agent@runloop.ai>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent d8b35a2 commit 227d0fd
1 file changed
Lines changed: 46 additions & 28 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
302 | 302 | | |
303 | 303 | | |
304 | 304 | | |
305 | | - | |
306 | | - | |
307 | | - | |
308 | | - | |
309 | | - | |
310 | | - | |
311 | | - | |
312 | | - | |
313 | | - | |
314 | | - | |
315 | | - | |
316 | | - | |
317 | | - | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
318 | 333 | | |
319 | 334 | | |
320 | 335 | | |
321 | | - | |
322 | 336 | | |
323 | | - | |
324 | | - | |
325 | | - | |
326 | | - | |
327 | | - | |
328 | | - | |
329 | | - | |
330 | | - | |
331 | | - | |
332 | | - | |
333 | | - | |
334 | | - | |
335 | | - | |
336 | | - | |
| 337 | + | |
337 | 338 | | |
338 | 339 | | |
339 | 340 | | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
340 | 358 | | |
341 | 359 | | |
342 | 360 | | |
| |||
0 commit comments