Log api boot phase timings (migrate
On main, rollout_phases.py measures 49.8-60.7s from task RUNNING to healthy in the target group (six deploys, 2026-10-16/17). The Terraform comment used to say ~10-15s. Nothing splits that time into migrate, seed, DBOS launch and uvicorn ready, so no one can tell which phase is slow.
- At api start, log one structured line per phase with its duration (migrate.upgrade, app.seed.main, DBOS launch, app ready).
- Have rollout_phases.py, or the deploy log, show the breakdown for the new task when it can read it.
- If one phase takes most of the time, file the fix for it.
Out of scope: the health-check grace (raised to 120s in Task 6695), the circuit breaker, the image build.
Done means:
- A main deploy log, or the api's CloudWatch log for a new task, shows per-phase boot durations that add up to the measured boot.
Outcome
The api now logs each boot phase. The deploy log adds them up to the measured boot (dev: -9.0 + 16.7 + 51.8 = 59.5s). The 51.8s after app ready is the slow part, filed as draft Task 6824. PR #5661 merged; quick gate green. Not yet seen on main: promotion is human-gated.
Artifacts
Activity
- Created
- Run
- Runner started
- Runner ended (done)