add evidence and report.md

This commit is contained in:
2026-10-27 00:18:03 +03:00
parent 8ad0bb6947
commit a7223cf164
22 changed files with 968 additions and 39 deletions
+15
View File
@@ -0,0 +1,15 @@
date: 2026-10-26T20:56:01Z
commit: 8ad0bb6 (+ uncommitted changes)
branch: solution/BPI2303-Grigoryan
cpu: Intel(R) Core(TM) i7-10510U CPU @ 1.80GHz (8 threads)
memory: 15Gi
kernel: 7.2.11-zen1-1-zen
docker: 29.9.2
compose: 5.6.1
python: Python 3.12.14
stand: http://localhost:18080 (compose project mtusi2026lab2-fork-test)
SERVICE IMAGE STATUS
api mtusi-messenger:lab2 Up 2 seconds (health: starting)
postgres postgres:16.10-bookworm Up 9 seconds (healthy)
redis redis:7.4.2-bookworm Up 9 seconds (healthy)
+113
View File
@@ -0,0 +1,113 @@
tests/test_auth.py::test_login_returns_opaque_bearer_session PASSED [ 0%]
tests/test_auth.py::test_each_login_issues_a_different_token PASSED [ 1%]
tests/test_auth.py::test_password_with_colon_works PASSED [ 2%]
tests/test_auth.py::test_unicode_password_works PASSED [ 3%]
tests/test_auth.py::test_wrong_password_and_unknown_user_look_identical PASSED [ 4%]
tests/test_auth.py::test_login_requires_basic_scheme PASSED [ 5%]
tests/test_auth.py::test_business_endpoints_require_bearer PASSED [ 6%]
tests/test_auth.py::test_x_user_id_cannot_override_bearer_identity PASSED [ 7%]
tests/test_auth.py::test_logout_revokes_only_current_session PASSED [ 8%]
tests/test_auth.py::test_logout_twice_returns_401 PASSED [ 8%]
tests/test_auth.py::test_session_expires_after_ttl PASSED [ 9%]
tests/test_auth.py::test_token_is_stored_only_as_sha256_key PASSED [ 10%]
tests/test_auth.py::test_password_is_not_stored_in_plaintext PASSED [ 11%]
tests/test_auth.py::test_login_rejects_out_of_range_password_like_wrong_password PASSED [ 12%]
tests/test_auth.py::test_malformed_basic_credentials_return_401 PASSED [ 13%]
tests/test_auth.py::test_unknown_user_takes_comparable_time_to_wrong_password PASSED [ 14%]
tests/test_chats.py::test_create_and_get_chat PASSED [ 15%]
tests/test_chats.py::test_chat_is_not_visible_to_outsider PASSED [ 16%]
tests/test_chats.py::test_chat_creation_requires_creator_in_members PASSED [ 16%]
tests/test_chats.py::test_chat_payload_boundaries[payload0] PASSED [ 17%]
tests/test_chats.py::test_chat_payload_boundaries[payload1] PASSED [ 18%]
tests/test_chats.py::test_duplicate_members_are_rejected PASSED [ 19%]
tests/test_chats.py::test_unknown_member_is_rejected PASSED [ 20%]
tests/test_chats.py::test_chat_exact_title_limit_is_accepted PASSED [ 21%]
tests/test_chats.py::test_chat_list_hides_chats_without_membership PASSED [ 22%]
tests/test_chats.py::test_nonexistent_chat_returns_404 PASSED [ 23%]
tests/test_chats.py::test_failed_chat_creation_leaves_no_partial_data PASSED [ 24%]
tests/test_chats.py::test_chat_list_pagination_and_order PASSED [ 25%]
tests/test_chats.py::test_chat_endpoints_require_bearer PASSED [ 25%]
tests/test_concurrency.py::test_parallel_registration_of_same_username_creates_exactly_one_user PASSED [ 26%]
tests/test_concurrency.py::test_100_messages_from_10_clients PASSED [ 27%]
tests/test_concurrency.py::test_chat_creation_in_parallel_is_atomic PASSED [ 28%]
tests/test_concurrency.py::test_parallel_registration_of_distinct_usernames_all_succeed PASSED [ 29%]
tests/test_concurrency.py::test_parallel_logins_issue_distinct_valid_tokens PASSED [ 30%]
tests/test_concurrency.py::test_parallel_logout_of_same_token_succeeds_once PASSED [ 31%]
tests/test_concurrency.py::test_message_limit_is_exact_under_concurrency PASSED [ 32%]
tests/test_concurrency.py::test_failed_chat_insert_rolls_back_whole_transaction PASSED [ 33%]
tests/test_constraints.py::test_duplicate_username_is_rejected_by_database PASSED [ 33%]
tests/test_constraints.py::test_message_requires_existing_chat PASSED [ 34%]
tests/test_constraints.py::test_duplicate_membership_is_rejected_by_database PASSED [ 35%]
tests/test_errors.py::test_missing_token_returns_401 PASSED [ 36%]
tests/test_errors.py::test_garbage_token_returns_401 PASSED [ 37%]
tests/test_errors.py::test_malformed_json_returns_400 PASSED [ 38%]
tests/test_errors.py::test_not_found_returns_404 PASSED [ 39%]
tests/test_errors.py::test_method_not_allowed_preserves_405 PASSED [ 40%]
tests/test_errors.py::test_unhandled_exception_is_hidden_from_client PASSED [ 41%]
tests/test_errors.py::test_success_response_contains_request_id PASSED [ 41%]
tests/test_failures.py::test_redis_down_gives_503_for_login_and_protected_endpoints PASSED [ 42%]
tests/test_failures.py::test_redis_down_keeps_registration_working PASSED [ 43%]
tests/test_failures.py::test_database_down_with_valid_session_gives_503 PASSED [ 44%]
tests/test_failures.py::test_dependency_failure_never_authenticates_anonymous_requests PASSED [ 45%]
tests/test_health.py::test_liveness PASSED [ 46%]
tests/test_health.py::test_readiness PASSED [ 47%]
tests/test_health.py::test_readiness_is_503_when_database_is_down PASSED [ 48%]
tests/test_health.py::test_business_request_is_503_when_database_is_down PASSED [ 49%]
tests/test_history_plan.py::test_history_page_uses_composite_index PASSED [ 50%]
tests/test_limits.py::test_message_limit_rejects_without_deleting_confirmed_messages PASSED [ 50%]
tests/test_limits.py::test_in_flight_limit_returns_429_and_recovers PASSED [ 51%]
tests/test_messages.py::test_send_and_list_message PASSED [ 52%]
tests/test_messages.py::test_invalid_message_text[] PASSED [ 53%]
tests/test_messages.py::test_invalid_message_text[ ] PASSED [ 54%]
tests/test_messages.py::test_invalid_message_text[xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx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xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx] PASSED [ 55%]
tests/test_messages.py::test_extra_message_field_is_rejected PASSED [ 56%]
tests/test_messages.py::test_messages_are_private_to_chat_members PASSED [ 57%]
tests/test_messages.py::test_pagination_has_no_duplicates PASSED [ 58%]
tests/test_messages.py::test_cursor_cannot_be_used_for_another_chat PASSED [ 58%]
tests/test_messages.py::test_limit_boundaries[0-400] PASSED [ 59%]
tests/test_messages.py::test_limit_boundaries[1-200] PASSED [ 60%]
tests/test_messages.py::test_limit_boundaries[100-200] PASSED [ 61%]
tests/test_messages.py::test_limit_boundaries[101-400] PASSED [ 62%]
tests/test_messages.py::test_message_exact_max_length_is_accepted PASSED [ 63%]
tests/test_messages.py::test_nonexistent_chat_messages_return_404 PASSED [ 64%]
tests/test_messages.py::test_unauthenticated_requests_are_rejected PASSED [ 65%]
tests/test_messages.py::test_messages_survive_new_login PASSED [ 66%]
tests/test_messages.py::test_history_order_is_created_at_then_id PASSED [ 66%]
tests/test_migrations.py::test_upgrade_creates_all_tables PASSED [ 67%]
tests/test_migrations.py::test_upgrade_twice_is_idempotent_and_keeps_data PASSED [ 68%]
tests/test_migrations.py::test_models_and_migrations_are_in_sync PASSED [ 69%]
tests/test_pagination.py::test_garbage_cursor_returns_400[not-base64-%%%] PASSED [ 70%]
tests/test_pagination.py::test_garbage_cursor_returns_400[bm90IGpzb24=] PASSED [ 71%]
tests/test_pagination.py::test_garbage_cursor_returns_400[WzEsIDIsIDNd] PASSED [ 72%]
tests/test_pagination.py::test_garbage_cursor_returns_400[eyJraW5kIjogIm1lc3NhZ2VzIn0=] PASSED [ 73%]
tests/test_pagination.py::test_cursor_without_timezone_is_rejected PASSED [ 74%]
tests/test_pagination.py::test_chat_list_cursor_is_bound_to_its_owner PASSED [ 75%]
tests/test_pagination.py::test_messages_cursor_is_not_accepted_by_chat_list PASSED [ 75%]
tests/test_pagination.py::test_limit_can_change_between_pages PASSED [ 76%]
tests/test_pagination.py::test_message_sent_after_reading_last_page_is_seen_with_cursor PASSED [ 77%]
tests/test_sessions.py::test_session_key_ttl_matches_expires_at PASSED [ 78%]
tests/test_sessions.py::test_session_ttl_is_absolute_and_not_extended_by_activity PASSED [ 79%]
tests/test_sessions.py::test_logout_removes_session_key PASSED [ 80%]
tests/test_sessions.py::test_expired_session_is_rejected_everywhere PASSED [ 81%]
tests/test_sessions.py::test_relogin_after_expiry_issues_new_working_token PASSED [ 82%]
tests/test_sessions.py::test_tampered_token_is_rejected PASSED [ 83%]
tests/test_sessions.py::test_session_of_deleted_user_is_rejected PASSED [ 83%]
tests/test_sessions.py::test_redis_flush_invalidates_all_sessions PASSED [ 84%]
tests/test_sessions.py::test_sessions_survive_redis_restart PASSED [ 85%]
tests/test_users.py::test_register_does_not_leak_password PASSED [ 86%]
tests/test_users.py::test_get_current_user PASSED [ 87%]
tests/test_users.py::test_invalid_user_payloads[body0] PASSED [ 88%]
tests/test_users.py::test_invalid_user_payloads[body1] PASSED [ 89%]
tests/test_users.py::test_invalid_user_payloads[body2] PASSED [ 90%]
tests/test_users.py::test_invalid_user_payloads[body3] PASSED [ 91%]
tests/test_users.py::test_invalid_user_payloads[body4] PASSED [ 91%]
tests/test_users.py::test_invalid_user_payloads[body5] PASSED [ 92%]
tests/test_users.py::test_invalid_user_payloads[body6] PASSED [ 93%]
tests/test_users.py::test_invalid_user_payloads[body7] PASSED [ 94%]
tests/test_users.py::test_invalid_user_payloads[body8] PASSED [ 95%]
tests/test_users.py::test_invalid_user_payloads[body9] PASSED [ 96%]
tests/test_users.py::test_password_length_boundaries_are_accepted PASSED [ 97%]
tests/test_users.py::test_extra_user_field_is_rejected PASSED [ 98%]
tests/test_users.py::test_duplicate_username_returns_conflict PASSED [ 99%]
tests/test_users.py::test_user_exact_length_boundaries_are_accepted PASSED [100%]
============================= 112 passed in 38.60s =============================
+1
View File
@@ -0,0 +1 @@
PASS: lab2 public API scenario; infrastructure and grading evidence remain separate.
+14
View File
@@ -0,0 +1,14 @@
== before
SERVICE STATUS
api Up 43 seconds (healthy)
postgres Up 51 seconds (healthy)
redis Up 3 seconds (health: starting)
Executing explicit persistence hook; hook output suppressed to avoid leaking secrets.
PASS: persistence preserved confirmed data and existing session. Hook scope needs operator evidence.
== after (Up N seconds = container was restarted by scripts/restart.sh)
SERVICE STATUS
api Up 5 seconds (healthy)
postgres Up 12 seconds (healthy)
redis Up 14 seconds (healthy)
+51
View File
@@ -0,0 +1,51 @@
messages in table: 50003; target chat: 10000; noise chat: 40000
== first page (limit+1 = 51)
SELECT * FROM messages
WHERE chat_id = :chat_id
ORDER BY created_at, id
LIMIT :page
Limit (actual time=0.006..0.015 rows=51 loops=1)
Buffers: shared hit=4
-> Index Scan using ix_messages_chat_id_created_at_id on messages (actual time=0.006..0.012 rows=51 loops=1)
Index Cond: (chat_id = '87629e85-f573-467a-b369-74d67ea5f2ac'::uuid)
Buffers: shared hit=4
Planning:
Buffers: shared hit=6
Planning Time: 0.051 ms
Execution Time: 0.025 ms
== page after cursor in the middle of history
SELECT * FROM messages
WHERE chat_id = :chat_id AND (created_at, id) > (:after_created_at, :after_id)
ORDER BY created_at, id
LIMIT :page
Limit (actual time=0.007..0.023 rows=51 loops=1)
Buffers: shared hit=6
-> Index Scan using ix_messages_chat_id_created_at_id on messages (actual time=0.007..0.020 rows=51 loops=1)
Index Cond: ((chat_id = '87629e85-f573-467a-b369-74d67ea5f2ac'::uuid) AND (ROW(created_at, id) > ROW('2026-10-26 19:33:40.369572+00'::timestamp with time zone, '540382ff-297f-48c1-8515-aca3063b8347'::uuid)))
Buffers: shared hit=6
Planning Time: 0.044 ms
Execution Time: 0.046 ms
== same page with index scans disabled (for comparison)
SELECT * FROM messages
WHERE chat_id = :chat_id AND (created_at, id) > (:after_created_at, :after_id)
ORDER BY created_at, id
LIMIT :page
Limit (actual time=4.477..4.483 rows=51 loops=1)
Buffers: shared hit=618
-> Sort (actual time=4.476..4.479 rows=51 loops=1)
Sort Key: created_at, id
Sort Method: top-N heapsort Memory: 31kB
Buffers: shared hit=618
-> Seq Scan on messages (actual time=0.417..4.025 rows=4999 loops=1)
Filter: ((chat_id = '87629e85-f573-467a-b369-74d67ea5f2ac'::uuid) AND (ROW(created_at, id) > ROW('2026-10-26 19:33:40.369572+00'::timestamp with time zone, '540382ff-297f-48c1-8515-aca3063b8347'::uuid)))
Rows Removed by Filter: 45004
Buffers: shared hit=618
Planning Time: 0.038 ms
Execution Time: 4.496 ms
+23
View File
@@ -0,0 +1,23 @@
== baseline
GET /users/me (Bearer) -> 200 (0.003616s)
== redis stopped
GET /users/me (Bearer) -> 503 (1.030640s)
POST /auth/sessions (Basic) -> 503 (0.677546s)
GET /users/me (no token) -> 401 (0.001655s)
GET /health/ready -> 503 (0.010732s)
GET /health/live -> 200 (0.001545s)
-- redis started again (AOF restored)
GET /users/me (same token) -> 200 (0.004750s)
== postgres stopped
GET /users/me (Bearer) -> 503 (0.403928s)
GET /api/v1/chats (Bearer) -> 503 (0.011329s)
GET /health/ready -> 503 (0.170920s)
GET /health/live -> 200 (0.004790s)
-- postgres started again
GET /users/me (same token) -> 200 (0.010434s)
== logout
DELETE /auth/sessions/current -> 204 (0.012516s)
GET /users/me (same token) -> 401 (0.002182s)
+10
View File
@@ -0,0 +1,10 @@
appendonly yes
appendfsync always
maxmemory 268435456
maxmemory-policy noeviction
dir /data
loading:0
aof_enabled:1
aof_last_bgrewrite_status:ok
aof_last_write_status:ok
+4
View File
@@ -0,0 +1,4 @@
NAME CPU % MEM USAGE / LIMIT
mtusi2026lab2-fork-test-api-1 94.22% 73.3MiB / 15.27GiB
mtusi2026lab2-fork-test-postgres-1 17.48% 40.43MiB / 15.27GiB
mtusi2026lab2-fork-test-redis-1 0.95% 10.62MiB / 15.27GiB
+17
View File
@@ -0,0 +1,17 @@
{
"lab": 2,
"workload": "closed-loop POST messages; no automatic retries",
"requested_duration_seconds": 20.0,
"elapsed_seconds": 20.059,
"concurrency": 8,
"successful_requests": 3050,
"failed_requests": 0,
"error_ratio": 0.0,
"successful_rps": 152.049,
"successful_latency_ms": {
"p50": 41.84,
"p95": 128.928,
"p99": 185.164
},
"note": "Latency percentiles cover successes only. Timeouts/errors are counted separately; closed-loop has coordinated omission and client overhead."
}
+5
View File
@@ -0,0 +1,5 @@
SESSION_TTL_SECONDS=3, login at 20:58:36Z, expires_at=2026-10-26T20:58:39.512095Z
GET /users/me right after login -> 200
GET /users/me after 4 s -> 401
DELETE /auth/sessions/current after -> 401
GET /users/me with new login token -> 200