Fix: reject revoked tokens on all replicas when Redis writes fail

This commit is contained in:
2026-10-23 22:33:12 +03:00
parent af184cabe3
commit 4abbe84847
42 changed files with 876 additions and 501 deletions
+11 -11
View File
@@ -1,20 +1,20 @@
# clean copy of the working tree (git ls-files -co --exclude-standard), fresh secrets and volume, COMPOSE_PROJECT_NAME=lab3-clean
# 2026-10-23T12:49Z, base commit 92c2fdc + uncommitted lab3 grade-4 changes
$ ./scripts/init-secrets.sh && docker compose up -d --build --wait && make check && make test && make test-persistence ACTION_SCRIPT=scripts/restart.sh && make test-failover ACTION_SCRIPT=scripts/stop-one.sh
# 2026-10-23T19:07Z, base commit af184ca + fix of session revocation across replicas
$ ./scripts/init-secrets.sh && docker compose up -d --build --wait && make check && make test && make test-persistence ACTION_SCRIPT=scripts/restart.sh && make test-failover ACTION_SCRIPT=scripts/stop-one.sh && PAUSE_MS=5000 scripts/revocation-pause.sh
created secrets/db_password
created secrets/redis_password
config ok
Container lab3-clean-api-2 Healthy
Container lab3-clean-api-1 Healthy
Container lab3-clean-lb-1 Healthy
PASS: offline skeleton structure, local refs and Python syntax; application NOT tested.
PASS: lab3 public API scenario; infrastructure and grading evidence remain separate.
PASS: persistence preserved confirmed data and existing session. Hook scope needs operator evidence.
{"observed_instances_before": 2, "successful_writes": 125, "failed_attempts": 0, "first_recovery_seconds": 4.859}
{"observed_instances_before": 2, "successful_writes": 125, "failed_attempts": 0, "first_recovery_seconds": 4.945}
PASS: failover preserved confirmed data and existing session. Hook scope needs operator evidence.
lab3-clean-api-1 running
lab3-clean-api-2 exited
lab3-clean-lb-1 running
lab3-clean-migrate-1 exited
lab3-clean-postgres-1 running
lab3-clean-redis-1 running
GET /users/me -> 200 e4b51cb6e956
GET /users/me -> 200 20b26306c56f
GET /users/me -> 200 e4b51cb6e956
GET /users/me -> 200 20b26306c56f
DELETE /auth/sessions/current -> 204 e4b51cb6e956 after 5.09 s
GET /users/me -> 401 20b26306c56f
GET /users/me -> 401 e4b51cb6e956
GET /users/me -> 401 20b26306c56f