ЛР4: обновить отчёт и доказательства для ревизии 02fc97b

This commit is contained in:
IvanMeln1k
2026-12-04 14:35:25 +03:00
parent 02fc97b78a
commit 31ab129e8a
37 changed files with 992 additions and 984 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
### attachment_checks
### command: make PYTHON=/usr/bin/python3 test-attachment
### started_at: 2026-12-04T11:20:46Z
### started_at: 2026-12-04T11:31:07Z
/usr/bin/python3 student-tests/attachment-checks.py --base-url "http://127.0.0.1:8084"
PASS size and pixel limits
PASS MIME, damage and filename display
+7 -7
View File
@@ -1,20 +1,20 @@
### container_checks
### command: make PYTHON=/usr/bin/python3 test-container
### started_at: 2026-12-04T11:21:34Z
### started_at: 2026-12-04T11:31:52Z
/usr/bin/python3 scripts/container-checks.py --base-url "http://127.0.0.1:8084"
lab4 container checks at 2026-12-04T11:21:36.286068Z
lab4 container checks at 2026-12-04T11:31:54.054715Z
result: PASS
git revision: f1fae32722dd89c48369ae92a303287c93490ed0
API replicas: 2 (b685ff3f08d3, c3f381c822ae)
API image ids: sha256:743995b25b1abba227d84d4e23f016e2121916cc68f4c032670eb8c24203314b
git revision: 02fc97b78aff9a1890bd2bade40f6cd8654e2000
API replicas: 2 (40fdc2d47091, 3e58d4b42901)
API image ids: sha256:9f46ec2a6cf007f77202d3ae97afc0f710ee3cd191b8c620405f397b193932ce
S3 image id: sha256:0513e5e469b80438fcb8961e4b7c422e782251114d4930ac17cd9fbe508ad5ba
API ports published: {'mtusi-lab4-melnikov-api-1': '', 'mtusi-lab4-melnikov-api-2': ''}
S3 ports published: ''
LB ports: 8080/tcp -> 127.0.0.1:8084
volumes: mtusi-lab4-melnikov-pgdata, mtusi-lab4-melnikov-s3data, mtusi-lab4-melnikov-valkeydata
limits: {"api":[{"name":"mtusi-lab4-melnikov-api-1","nano_cpus":500000000,"memory_bytes":402653184,"readonly_rootfs":true,"cap_drop":["ALL"],"security_opt":["no-new-privileges:true"],"user":"10001:10001","mounts":[],"volume_mounts":[]},{"name":"mtusi-lab4-melnikov-api-2","nano_cpus":500000000,"memory_bytes":402653184,"readonly_rootfs":true,"cap_drop":["ALL"],"security_opt":["no-new-privileges:true"],"user":"10001:10001","mounts":[],"volume_mounts":[]}],"postgres":[{"name":"mtusi-lab4-melnikov-postgres-1","nano_cpus":500000000,"memory_bytes":402653184,"readonly_rootfs":false,"cap_drop":null,"security_opt":["no-new-privileges:true"],"user":"","mounts":["mtusi-lab4-melnikov-pgdata"],"volume_mounts":["mtusi-lab4-melnikov-pgdata"]}],"valkey":[{"name":"mtusi-lab4-melnikov-valkey-1","nano_cpus":100000000,"memory_bytes":100663296,"readonly_rootfs":false,"cap_drop":null,"security_opt":["no-new-privileges:true"],"user":"","mounts":["mtusi-lab4-melnikov-valkeydata"],"volume_mounts":["mtusi-lab4-melnikov-valkeydata"]}],"s3":[{"name":"mtusi-lab4-melnikov-s3-1","nano_cpus":400000000,"memory_bytes":402653184,"readonly_rootfs":false,"cap_drop":null,"security_opt":["no-new-privileges:true"],"user":"","mounts":["/Users/ivanmuller/Desktop/oh_my_life/highload/lab4/infra/seaweedfs-s3.json","mtusi-lab4-melnikov-s3data"],"volume_mounts":["mtusi-lab4-melnikov-s3data"]}],"lb":[{"name":"mtusi-lab4-melnikov-lb-1","nano_cpus":200000000,"memory_bytes":67108864,"readonly_rootfs":true,"cap_drop":["ALL"],"security_opt":["no-new-privileges:true"],"user":"haproxy","mounts":["/Users/ivanmuller/Desktop/oh_my_life/highload/lab4/infra/haproxy.cfg"],"volume_mounts":[]}]}
observed session instances: b685ff3f08d3, c3f381c822ae
limits: {"api":[{"name":"mtusi-lab4-melnikov-api-1","nano_cpus":500000000,"memory_bytes":402653184,"readonly_rootfs":true,"cap_drop":["ALL"],"security_opt":["no-new-privileges:true"],"user":"10001:10001","mounts":[],"volume_mounts":[]},{"name":"mtusi-lab4-melnikov-api-2","nano_cpus":500000000,"memory_bytes":402653184,"readonly_rootfs":true,"cap_drop":["ALL"],"security_opt":["no-new-privileges:true"],"user":"10001:10001","mounts":[],"volume_mounts":[]}],"postgres":[{"name":"mtusi-lab4-melnikov-postgres-1","nano_cpus":500000000,"memory_bytes":402653184,"readonly_rootfs":false,"cap_drop":null,"security_opt":["no-new-privileges:true"],"user":"","mounts":["mtusi-lab4-melnikov-pgdata"],"volume_mounts":["mtusi-lab4-melnikov-pgdata"]}],"valkey":[{"name":"mtusi-lab4-melnikov-valkey-1","nano_cpus":100000000,"memory_bytes":100663296,"readonly_rootfs":false,"cap_drop":null,"security_opt":["no-new-privileges:true"],"user":"","mounts":["mtusi-lab4-melnikov-valkeydata"],"volume_mounts":["mtusi-lab4-melnikov-valkeydata"]}],"s3":[{"name":"mtusi-lab4-melnikov-s3-1","nano_cpus":400000000,"memory_bytes":402653184,"readonly_rootfs":false,"cap_drop":null,"security_opt":["no-new-privileges:true"],"user":"","mounts":["mtusi-lab4-melnikov-s3data","/Users/ivanmuller/Desktop/oh_my_life/highload/lab4/infra/seaweedfs-s3.json"],"volume_mounts":["mtusi-lab4-melnikov-s3data"]}],"lb":[{"name":"mtusi-lab4-melnikov-lb-1","nano_cpus":200000000,"memory_bytes":67108864,"readonly_rootfs":true,"cap_drop":["ALL"],"security_opt":["no-new-privileges:true"],"user":"haproxy","mounts":["/Users/ivanmuller/Desktop/oh_my_life/highload/lab4/infra/haproxy.cfg"],"volume_mounts":[]}]}
observed session instances: 3e58d4b42901, 40fdc2d47091
anonymous object GET denied: True
anonymous bucket list denied: True
bootstrap second run: exit=0 created_false=True
+5 -5
View File
@@ -1,14 +1,14 @@
started_at: 2026-12-04T11:20:34Z
started_at: 2026-12-04T11:30:56Z
base_url: http://127.0.0.1:8084
git_revision: f1fae32722dd89c48369ae92a303287c93490ed0
git_status_lines: 6
git_revision: 02fc97b78aff9a1890bd2bade40f6cd8654e2000
git_status_lines: 1
python3: Python 3.14.4
python39: Python 3.9.6
go: go version go1.25.1 darwin/arm64
docker_server: 27.4.0
docker_cpus_mem: CPUs=2 MemTotal=2054631424
api_images:
/mtusi-lab4-melnikov-api-1 image=sha256:743995b25b1abba227d84d4e23f016e2121916cc68f4c032670eb8c24203314b started=2026-12-04T11:20:31.647058664Z
/mtusi-lab4-melnikov-api-2 image=sha256:743995b25b1abba227d84d4e23f016e2121916cc68f4c032670eb8c24203314b started=2026-12-04T11:20:31.736803769Z
/mtusi-lab4-melnikov-api-1 image=sha256:9f46ec2a6cf007f77202d3ae97afc0f710ee3cd191b8c620405f397b193932ce started=2026-12-04T11:30:54.036964331Z
/mtusi-lab4-melnikov-api-2 image=sha256:9f46ec2a6cf007f77202d3ae97afc0f710ee3cd191b8c620405f397b193932ce started=2026-12-04T11:30:53.915503045Z
s3_image:
/mtusi-lab4-melnikov-s3-1 image=sha256:0513e5e469b80438fcb8961e4b7c422e782251114d4930ac17cd9fbe508ad5ba
+2 -2
View File
@@ -1,10 +1,10 @@
### experiment
### command: make PYTHON=/usr/bin/python3 experiment
### started_at: 2026-12-04T11:24:35Z
### started_at: 2026-12-04T11:34:51Z
/usr/bin/python3 scripts/upload-experiment.py --base-url "http://127.0.0.1:8084"
== restart API replicas to reset the process high-water mark ==
== generate the reproducible upload profile ==
{"result": "PASS", "observed_peak_concurrency": 12, "successful_uploads": 12, "wall_seconds": 1.025, "process_peak_sampled_rss_bytes": {"773413b3e9bd": 72986624, "9d9d4b6abf35": 27385856}, "process_final_hwm_bytes": {"773413b3e9bd": 74690560, "9d9d4b6abf35": 53465088}, "api_memory_limit_bytes": 402653184}
{"result": "PASS", "observed_peak_concurrency": 12, "successful_uploads": 12, "wall_seconds": 1.088, "process_peak_sampled_rss_bytes": {"255348db8382": 53067776, "291762b7fcf7": 43819008}, "process_final_hwm_bytes": {"255348db8382": 53592064, "291762b7fcf7": 53338112}, "api_memory_limit_bytes": 402653184}
PASS: >=10 concurrent uploads with bounded API process RSS
### exit_code: 0
+2 -2
View File
@@ -1,9 +1,9 @@
### failover_public
### command: make PYTHON=/usr/bin/python3 test-failover ACTION_SCRIPT=scripts/stop-one.sh
### started_at: 2026-12-04T11:23:22Z
### started_at: 2026-12-04T11:33:37Z
/usr/bin/python3 tests/resilience.py --mode failover --action-script "scripts/stop-one.sh" --base-url "http://127.0.0.1:8084"
Executing explicit failover hook; hook output suppressed to avoid leaking secrets.
{"observed_instances_before": 2, "successful_writes": 135, "failed_attempts": 0, "first_recovery_seconds": 3.205}
{"observed_instances_before": 2, "successful_writes": 139, "failed_attempts": 0, "first_recovery_seconds": 3.246}
PASS: failover preserved confirmed data and existing session. Hook scope needs operator evidence.
### exit_code: 0
+2 -2
View File
@@ -1,7 +1,7 @@
### failover_upload
### command: /usr/bin/python3 scripts/failover-upload.py --base-url http://127.0.0.1:8084
### started_at: 2026-12-04T11:23:42Z
{"upload_instance": "773413b3e9bd", "download_instance": "9d9d4b6abf35", "instances_seen": ["9d9d4b6abf35"], "sha256_matches": true, "stopped_container_state": "exited", "restored_at": "2026-12-04T11:23:46.540443Z"}
### started_at: 2026-12-04T11:33:57Z
{"upload_instance": "255348db8382", "download_instance": "291762b7fcf7", "instances_seen": ["291762b7fcf7"], "sha256_matches": true, "stopped_container_state": "exited", "restored_at": "2026-12-04T11:34:01.329817Z"}
PASS: upload survived replica stop and downloaded with the same SHA-256 via another replica
### exit_code: 0
+8 -8
View File
@@ -1,7 +1,7 @@
### go_race
### command: make PYTHON=/usr/bin/python3 test-student-race
### started_at: 2026-12-04T11:20:39Z
### started_at: 2026-12-04T11:31:00Z
go test -race -count=1 ./...
? mtusi.ru/messenger-lab4/cmd/loadgen [no test files]
? mtusi.ru/messenger-lab4/cmd/messenger [no test files]
@@ -9,13 +9,13 @@ go test -race -count=1 ./...
? mtusi.ru/messenger-lab4/cmd/reconciler [no test files]
? mtusi.ru/messenger-lab4/cmd/s3bootstrap [no test files]
? mtusi.ru/messenger-lab4/cmd/s3ctl [no test files]
ok mtusi.ru/messenger-lab4/internal/api 1.203s
ok mtusi.ru/messenger-lab4/internal/auth 4.034s
ok mtusi.ru/messenger-lab4/internal/config 1.783s
ok mtusi.ru/messenger-lab4/internal/cursor 1.299s
ok mtusi.ru/messenger-lab4/internal/model 1.419s
ok mtusi.ru/messenger-lab4/internal/api 1.608s
ok mtusi.ru/messenger-lab4/internal/auth 3.915s
ok mtusi.ru/messenger-lab4/internal/config 1.307s
ok mtusi.ru/messenger-lab4/internal/cursor 1.166s
ok mtusi.ru/messenger-lab4/internal/model 1.723s
? mtusi.ru/messenger-lab4/internal/objectstore [no test files]
? mtusi.ru/messenger-lab4/internal/session [no test files]
ok mtusi.ru/messenger-lab4/internal/store 1.660s
ok mtusi.ru/messenger-lab4/internal/uuid 1.896s
ok mtusi.ru/messenger-lab4/internal/store 1.871s
ok mtusi.ru/messenger-lab4/internal/uuid 2.008s
### exit_code: 0
+7 -7
View File
@@ -1,7 +1,7 @@
### go_tests
### command: make PYTHON=/usr/bin/python3 test-student
### started_at: 2026-12-04T11:20:35Z
### started_at: 2026-12-04T11:30:57Z
go test -count=1 ./...
? mtusi.ru/messenger-lab4/cmd/loadgen [no test files]
? mtusi.ru/messenger-lab4/cmd/messenger [no test files]
@@ -9,14 +9,14 @@ go test -count=1 ./...
? mtusi.ru/messenger-lab4/cmd/reconciler [no test files]
? mtusi.ru/messenger-lab4/cmd/s3bootstrap [no test files]
? mtusi.ru/messenger-lab4/cmd/s3ctl [no test files]
ok mtusi.ru/messenger-lab4/internal/api 0.336s
ok mtusi.ru/messenger-lab4/internal/auth 0.388s
ok mtusi.ru/messenger-lab4/internal/config 0.849s
ok mtusi.ru/messenger-lab4/internal/cursor 0.435s
ok mtusi.ru/messenger-lab4/internal/model 0.967s
ok mtusi.ru/messenger-lab4/internal/api 0.251s
ok mtusi.ru/messenger-lab4/internal/auth 1.036s
ok mtusi.ru/messenger-lab4/internal/config 0.373s
ok mtusi.ru/messenger-lab4/internal/cursor 0.527s
ok mtusi.ru/messenger-lab4/internal/model 0.662s
? mtusi.ru/messenger-lab4/internal/objectstore [no test files]
? mtusi.ru/messenger-lab4/internal/session [no test files]
ok mtusi.ru/messenger-lab4/internal/store 0.552s
ok mtusi.ru/messenger-lab4/internal/store 0.945s
ok mtusi.ru/messenger-lab4/internal/uuid 1.080s
/usr/bin/python3 student-tests/blackbox.py --base-url "http://127.0.0.1:8084"
PASS health
+1 -1
View File
@@ -1,7 +1,7 @@
### make_check
### command: make PYTHON=/usr/bin/python3 check
### started_at: 2026-12-04T11:20:35Z
### started_at: 2026-12-04T11:30:57Z
/usr/bin/python3 scripts/check_contract.py
PASS: offline skeleton structure, local refs and Python syntax; application NOT tested.
### exit_code: 0
+1 -1
View File
@@ -1,7 +1,7 @@
### make_validate
### command: make PYTHON=.venv/bin/python validate
### started_at: 2026-12-04T11:20:35Z
### started_at: 2026-12-04T11:30:57Z
.venv/bin/python scripts/validate_openapi.py
/Users/ivanmuller/Desktop/oh_my_life/highload/lab4/.venv/lib/python3.9/site-packages/urllib3/__init__.py:35: NotOpenSSLWarning: urllib3 v2 only supports OpenSSL 1.1.1+, currently the 'ssl' module is compiled with 'LibreSSL 2.8.3'. See: https://github.com/urllib3/urllib3/issues/3020
warnings.warn(
+1 -1
View File
@@ -1,7 +1,7 @@
### persistence_evidence
### command: /usr/bin/python3 scripts/persistence-evidence.py --base-url http://127.0.0.1:8084
### started_at: 2026-12-04T11:22:29Z
### started_at: 2026-12-04T11:32:43Z
running scripts/restart.sh (all API replicas and used stores, volumes kept)
{"result": "PASS", "checks": {"same_container_ids": true, "started_at_changed": true, "all_services_restarted": true, "volumes_unchanged": true, "same_token_still_valid": true, "message_survived": true, "attachment_metadata_survived": true, "attachment_bytes_survived": true}}
PASS: real containers restarted, volumes and data preserved
+1 -1
View File
@@ -1,7 +1,7 @@
### persistence_public
### command: make PYTHON=/usr/bin/python3 test-persistence ACTION_SCRIPT=scripts/restart.sh
### started_at: 2026-12-04T11:21:36Z
### started_at: 2026-12-04T11:31:54Z
/usr/bin/python3 tests/resilience.py --mode persistence --action-script "scripts/restart.sh" --base-url "http://127.0.0.1:8084"
Executing explicit persistence hook; hook output suppressed to avoid leaking secrets.
PASS: persistence preserved confirmed data and existing session. Hook scope needs operator evidence.
+1 -1
View File
@@ -1,7 +1,7 @@
### smoke
### command: make PYTHON=/usr/bin/python3 test
### started_at: 2026-12-04T11:20:44Z
### started_at: 2026-12-04T11:31:05Z
/usr/bin/python3 tests/smoke.py --base-url "http://127.0.0.1:8084"
PASS: lab4 public API scenario; infrastructure and grading evidence remain separate.
### exit_code: 0
+1 -1
View File
@@ -1,7 +1,7 @@
### smoke_after_experiment
### command: make PYTHON=/usr/bin/python3 test
### started_at: 2026-12-04T11:24:42Z
### started_at: 2026-12-04T11:34:58Z
/usr/bin/python3 tests/smoke.py --base-url "http://127.0.0.1:8084"
PASS: lab4 public API scenario; infrastructure and grading evidence remain separate.
### exit_code: 0
+1 -1
View File
@@ -1,7 +1,7 @@
### smoke_python39
### command: ./scripts/py39-tests.sh
### started_at: 2026-12-04T11:20:44Z
### started_at: 2026-12-04T11:31:05Z
Python 3.9.6
PASS: offline skeleton structure, local refs and Python syntax; application NOT tested.
PASS: lab4 public API scenario; infrastructure and grading evidence remain separate.
+1 -1
View File
@@ -1,2 +1,2 @@
finished_at: 2026-12-04T11:24:43Z
finished_at: 2026-12-04T11:34:58Z
15 ### exit_code: 0
+2 -2
View File
@@ -1,7 +1,7 @@
### track2
### command: make PYTHON=/usr/bin/python3 test-consistency
### started_at: 2026-12-04T11:23:48Z
### started_at: 2026-12-04T11:34:02Z
/usr/bin/python3 scripts/track2.py --base-url "http://127.0.0.1:8084"
== reproducible base set ==
== cost of a clean traversal ==
@@ -11,6 +11,6 @@
== rerun before grace expiry: no new deletions ==
== grace expiry: the fresh orphan is now old enough ==
== API and used attachments after reconciliation ==
{"result": "PASS", "assertions": 68, "failed": 0, "cost_ms_median": 10}
{"result": "PASS", "assertions": 68, "failed": 0, "cost_ms_median": 11}
PASS: track 2 reconciler experiment
### exit_code: 0