Startup time and readiness
Worked example
This is an offline lesson. Data are fictional and Docker commands are unexecuted. Any optional execution requires an authorized disposable VM, a verified context, synthetic data, restricted access and no external transmission. Do not collect secrets or private output. Before any separately authorized Docker query, verify the effective endpoint and builder (including environment overrides), not just the context name. Use only disposable lab resources; a failed check is a stop condition, not permission to retry against a different host.
Synthetic timeline (seconds from invocation):create=0.4; process running=0.8; first successful readiness probe=3.5Observed readiness latency=3.5 s; process-to-probe=2.7 sProbe interval=0.5 s; true readiness may be earlier.Staged read-only checks: docker inspect bm29-demo; docker logs --tail 20 bm29-demoChoose a clear start point and use the same end condition in every run: for a service, a successful bounded request that verifies the expected response may be more meaningful than process creation. Polling observes readiness only at discrete times; record the probe interval and timeout, and count timed-out attempts as failures, not zero-duration successes. Keep image availability constant when comparing application startup; if pull time matters, report a separate end-to-end cold deployment metric. Database migrations, lazy initialization and VM wake-up can dominate initial latency. Docker health-check timing is another observed signal, not necessarily the exact moment readiness began. Do not remove essential initialization or weaken health checks to improve a graph. Verify first-request correctness and sustained readiness. Trial A has two successes and one timeout; its successful-only median is 2.25 s. Trial B has three successes and a median of 3 s. Only B meets the all-trials deadline. A successful probe bounds an observation, not an exact transition time, and an isolated passing probe does not establish sustained availability.
Common mistake
A faster running state is not a faster ready service. A timeout is a failed observation, not a missing value to silently discard.
Manual practice
Compare three synthetic readiness trials of 2.0 s, 2.5 s and timeout at 5 s with three successful trials of 3.0 s each. Report success counts and successful-only medians separately. Which meets a requirement of all trials ready within 4 s?
Worksheet: lab-fixtures/docker-performance-engineering/05-startup/scenario.txt.
Check Your Understanding
Solidify your learning with the interactive assessment directly below this lesson.
Concept Quiz & Questions
Startup time and readiness — Knowledge check
Interpret performance evidence and make a safe operational decision.
In the synthetic timeline, what is invocation-to-first-successful-probe latency?
How should timed-out readiness trials be reported?
Does the first successful probe identify the exact readiness instant?