date: 2026-10-30T04:29:33Z  commit: 81dd816
== before: api replicas (hostname = X-Instance-Id), state, StartedAt, FinishedAt
0cc3ee358e59 running started=2026-10-30T04:28:59.851144131Z finished=0001-01-01T00:00:00Z
899a952a5a21 running started=2026-10-30T04:29:31.104320507Z finished=2026-10-30T04:29:18.153900709Z
$ make test-failover ACTION_SCRIPT=scripts/stop-one.sh
python3 tests/resilience.py --mode failover --action-script "scripts/stop-one.sh" --base-url "http://127.0.0.1:18084" 
Executing explicit failover hook; hook output suppressed to avoid leaking secrets.
{"observed_instances_before": 2, "successful_writes": 128, "failed_attempts": 0, "first_recovery_seconds": 2.883}
PASS: failover preserved confirmed data and existing session. Hook scope needs operator evidence.
== after: api replicas
0cc3ee358e59 exited started=2026-10-30T04:28:59.851144131Z finished=2026-10-30T04:29:36.57527926Z
899a952a5a21 running started=2026-10-30T04:29:31.104320507Z finished=2026-10-30T04:29:18.153900709Z
== stopped replica: 0cc3ee358e59; shutdown: signal, drain window with readiness 503, close, exit
{"event":"Handling signal: term","level":"info","ts":"2026-10-30T04:29:34.045936Z"}
{"limit":2.0,"event":"service.draining","level":"info","ts":"2026-10-30T04:29:34.072243Z"}
{"limit":2.0,"event":"service.draining","level":"info","ts":"2026-10-30T04:29:34.126665Z"}
{"method":"GET","route":"/health/ready","status":503,"request_id":"6362781446fb427cbee670871ce5ef51","duration_ms":1.463,"event":"request.handled","level":"info","ts":"2026-10-30T04:29:34.446815Z"}
{"method":"GET","route":"/health/ready","status":503,"request_id":"0d9cf1c47fca4ec98ed599b113cd93db","duration_ms":0.79,"event":"request.handled","level":"info","ts":"2026-10-30T04:29:34.950067Z"}
{"event":"Shutting down","level":"info","ts":"2026-10-30T04:29:36.079497Z"}
{"event":"Shutting down","level":"info","ts":"2026-10-30T04:29:36.138465Z"}
{"event":"service.stopped","level":"info","ts":"2026-10-30T04:29:36.188615Z"}
{"event":"Finished server process [20]","level":"info","ts":"2026-10-30T04:29:36.188874Z"}
{"event":"service.stopped","level":"info","ts":"2026-10-30T04:29:36.247500Z"}
{"event":"Finished server process [19]","level":"info","ts":"2026-10-30T04:29:36.247910Z"}
{"event":"Worker (pid:20) was sent SIGTERM!","level":"info","ts":"2026-10-30T04:29:36.250957Z"}
{"event":"Worker (pid:19) was sent SIGTERM!","level":"info","ts":"2026-10-30T04:29:36.357386Z"}
{"event":"Shutting down: Master","level":"info","ts":"2026-10-30T04:29:36.468491Z"}
$ scripts/restore.sh
 Container mtusi2026lab4-api-2  Running
 Container mtusi2026lab4-api-1  Starting
 Container mtusi2026lab4-api-1  Started
 Container mtusi2026lab4-api-2  Waiting
 Container mtusi2026lab4-api-1  Waiting
 Container mtusi2026lab4-api-2  Healthy
 Container mtusi2026lab4-api-1  Healthy
== after restore
0cc3ee358e59 running started=2026-10-30T04:29:49.45750296Z finished=2026-10-30T04:29:36.57527926Z
899a952a5a21 running started=2026-10-30T04:29:31.104320507Z finished=2026-10-30T04:29:18.153900709Z
