ЛР 3 - БВТ2303 - Голиков - на 5, трек 1 #4

Closed
Maximillan_Mercer wants to merge 36 commits from Maximillan_Mercer/mtusi2026lab3-fork:solution/BVT2303-Golikov into main
3 changed files with 35 additions and 0 deletions
Showing only changes of commit 4886430b69 - Show all commits
+12
View File
@@ -0,0 +1,12 @@
# Лабораторная 3 — тест отказа (failover), прогон 2 (целевая реплика отличается от прогона 1)
# Дата: 2026-10-07
# Commit: a34c6e8
# Хост: Windows 10, Docker Desktop (бэкенд WSL2)
# Команда: make test-failover ACTION_SCRIPT=scripts/stop-one.cmd
# Пороги: first_recovery_seconds <= 10; observed_instances_before >= 2
# Цель: доказать, что остановить можно любую реплику, а не только первую
python3 tests/resilience.py --mode failover --action-script "scripts/stop-one.cmd" --base-url "http://localhost:8080"
Executing explicit failover hook; hook output suppressed to avoid leaking secrets.
{"observed_instances_before": 2, "successful_writes": 92, "failed_attempts": 2, "first_recovery_seconds": 2.487}
PASS: failover preserved confirmed data and existing session. Hook scope needs operator evidence.
+12
View File
@@ -0,0 +1,12 @@
# Лабораторная 3 — тест отказа (failover), прогон 1
# Дата: 2026-10-07
# Commit: a34c6e8
# Хост: Windows 10, Docker Desktop (бэкенд WSL2)
# Команда: make test-failover ACTION_SCRIPT=scripts/stop-one.cmd
# Пороги: first_recovery_seconds <= 10; observed_instances_before >= 2
# Примечание: лог восстановлен из вывода терминала (первый прогон не был сохранён через tee)
python3 tests/resilience.py --mode failover --action-script "scripts/stop-one.cmd" --base-url "http://localhost:8080"
Executing explicit failover hook; hook output suppressed to avoid leaking secrets.
{"observed_instances_before": 2, "successful_writes": 76, "failed_attempts": 3, "first_recovery_seconds": 2.466}
PASS: failover preserved confirmed data and existing session. Hook scope needs operator evidence.
+11
View File
@@ -0,0 +1,11 @@
# Лабораторная 3 — тест сохранности данных (persistence)
# Дата: 2026-10-07
# Commit: a34c6e8
# Хост: Windows 10, Docker Desktop (бэкенд WSL2)
# Команда: make test-persistence ACTION_SCRIPT=scripts/restart.cmd
# Action-скрипт: scripts/restart.cmd -> docker compose down && docker compose up -d
# Примечание: .cmd — локальная обёртка для Windows; на Linux используется scripts/restart.sh
python3 tests/resilience.py --mode persistence --action-script "scripts/restart.cmd" --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.