refactor code

This commit is contained in:
Матвей
2026-10-14 15:12:40 +03:00
parent 27cbf91b73
commit 6e7b8007ac
21 changed files with 86 additions and 515 deletions
+6
View File
@@ -0,0 +1,6 @@
$ make test-failover ACTION_SCRIPT=scripts/stop-one.sh
Executing explicit failover hook; hook output suppressed to avoid leaking secrets.
{"observed_instances_before": 2, "successful_writes": 129, "failed_attempts": 0, "first_recovery_seconds": 0.559}
PASS: failover preserved confirmed data and existing session. Hook scope needs operator evidence.
After the hook, `docker compose ps` showed api-b running and api-a stopped. api-a was then started and reached health=healthy.
+6
View File
@@ -0,0 +1,6 @@
$ make test-failover ACTION_SCRIPT=scripts/stop-one.sh
Executing explicit failover hook; hook output suppressed to avoid leaking secrets.
{"observed_instances_before": 2, "successful_writes": 130, "failed_attempts": 0, "first_recovery_seconds": 0.545}
PASS: failover preserved confirmed data and existing session. Hook scope needs operator evidence.
After the hook, `docker compose ps` showed api-a running and api-b stopped. api-b was then started and reached health=healthy.
@@ -0,0 +1,2 @@
$ python3 student-tests/idempotency_concurrency.py
PASS: concurrent idempotency through load balancer
+4
View File
@@ -0,0 +1,4 @@
$ make test-persistence ACTION_SCRIPT=scripts/restart.sh
python3 tests/resilience.py --mode persistence --action-script "scripts/restart.sh" --base-url "http://localhost:8080"
Executing explicit persistence hook; hook output suppressed to avoid leaking secrets.
PASS: persistence preserved confirmed data and existing session. Hook scope needs operator evidence.
+3
View File
@@ -0,0 +1,3 @@
$ make test
python3 tests/smoke.py --base-url "http://localhost:8080"
PASS: lab3 public API scenario; infrastructure and grading evidence remain separate.