lab2
Application / Линт, типы и собственные тесты (pull_request) Canceled after 0s
Application / Стенд Compose, smoke, рестарт и отказы зависимостей (pull_request) Canceled after 0s
Skeleton contracts / contracts (pull_request) Canceled after 0s

This commit is contained in:
Artyom
2026-10-30 12:32:42 +03:00
parent 65003b6119
commit 6d8b76b447
222 changed files with 19685 additions and 18 deletions
File diff suppressed because it is too large Load Diff
+552
View File
@@ -0,0 +1,552 @@
date: 2026-10-28T17:18:31.130Z commit: 6468ee2 17.11
EXPLAIN (ANALYZE, BUFFERS) при plan_cache_mode = force_custom_plan
=== none | largest (284708 сообщений) | first | тёплый кэш
Limit (cost=35863.74..35869.69 rows=51 width=176) (actual time=19.687..21.080 rows=51 loops=1)
Buffers: shared hit=14320 read=11464
-> Gather Merge (cost=35863.74..63557.67 rows=237360 width=176) (actual time=19.686..21.077 rows=51 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=14320 read=11464
-> Sort (cost=34863.71..35160.41 rows=118680 width=176) (actual time=18.751..18.753 rows=51 loops=3)
Sort Key: created_at, id
Sort Method: top-N heapsort Memory: 38kB
Buffers: shared hit=14320 read=11464
Worker 0: Sort Method: top-N heapsort Memory: 38kB
Worker 1: Sort Method: top-N heapsort Memory: 38kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=118680 width=176) (actual time=0.013..14.715 rows=94903 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Rows Removed by Filter: 238428
Buffers: shared hit=14232 read=11464
Planning Time: 0.059 ms
Execution Time: 21.103 ms
=== none | largest (284708 сообщений) | keyset_deep | тёплый кэш
Limit (cost=34387.32..34393.27 rows=51 width=176) (actual time=17.737..18.764 rows=51 loops=1)
Buffers: shared hit=702 read=25024
-> Gather Merge (cost=34387.32..37182.85 rows=23960 width=176) (actual time=17.736..18.761 rows=51 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=702 read=25024
-> Sort (cost=33387.29..33417.24 rows=11980 width=176) (actual time=16.550..16.551 rows=34 loops=3)
Sort Key: created_at, id
Sort Method: top-N heapsort Memory: 38kB
Buffers: shared hit=702 read=25024
Worker 0: Sort Method: top-N heapsort Memory: 38kB
Worker 1: Sort Method: top-N heapsort Memory: 38kB
-> Parallel Seq Scan on messages (cost=0.00..32987.62 rows=11980 width=176) (actual time=5.403..16.125 rows=9490 loops=3)
Filter: ((chat_id = '00000000-0000-7000-8000-000000000001'::uuid) AND (ROW(created_at, id) > ROW('2026-01-27 23:59:58.179187+00'::timestamp with time zone, '00000001-0000-7000-8002-00000003e8ed'::uuid)))
Rows Removed by Filter: 323841
Buffers: shared hit=672 read=25024
Planning Time: 0.083 ms
Execution Time: 18.778 ms
=== none | largest (284708 сообщений) | offset_deep | тёплый кэш
Limit (cost=79744.03..79744.15 rows=1 width=176) (actual time=58.869..60.326 rows=51 loops=1)
Buffers: shared hit=760 read=25024, temp read=6161 written=6660
-> Gather Merge (cost=52050.10..79744.03 rows=237360 width=176) (actual time=26.697..55.317 rows=256288 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=760 read=25024, temp read=6161 written=6660
-> Sort (cost=51050.07..51346.77 rows=118680 width=176) (actual time=25.251..31.125 rows=85598 loops=3)
Sort Key: created_at, id
Sort Method: external merge Disk: 18360kB
Buffers: shared hit=760 read=25024, temp read=6161 written=6660
Worker 0: Sort Method: external merge Disk: 16632kB
Worker 1: Sort Method: external merge Disk: 18144kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=118680 width=176) (actual time=0.018..14.215 rows=94903 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Rows Removed by Filter: 238428
Buffers: shared hit=672 read=25024
Planning Time: 0.074 ms
Execution Time: 60.862 ms
=== none | chat_50 (1761 сообщений) | first | тёплый кэш
Limit (cost=31923.34..31929.29 rows=51 width=176) (actual time=13.382..14.353 rows=51 loops=1)
Buffers: shared hit=760 read=25024
-> Gather Merge (cost=31923.34..32056.35 rows=1140 width=176) (actual time=13.381..14.350 rows=51 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=760 read=25024
-> Sort (cost=30923.31..30924.74 rows=570 width=176) (actual time=12.427..12.429 rows=51 loops=3)
Sort Key: created_at, id
Sort Method: top-N heapsort Memory: 38kB
Buffers: shared hit=760 read=25024
Worker 0: Sort Method: top-N heapsort Memory: 38kB
Worker 1: Sort Method: top-N heapsort Memory: 38kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=570 width=176) (actual time=10.425..12.342 rows=587 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Rows Removed by Filter: 332744
Buffers: shared hit=672 read=25024
Planning Time: 0.070 ms
Execution Time: 14.366 ms
=== none | chat_50 (1761 сообщений) | keyset_deep | тёплый кэш
Limit (cost=33989.34..33995.29 rows=51 width=176) (actual time=14.321..15.468 rows=51 loops=1)
Buffers: shared hit=702 read=25024
-> Gather Merge (cost=33989.34..34002.87 rows=116 width=176) (actual time=14.321..15.465 rows=51 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=702 read=25024
-> Sort (cost=32989.31..32989.46 rows=58 width=176) (actual time=13.344..13.345 rows=17 loops=3)
Sort Key: created_at, id
Sort Method: top-N heapsort Memory: 38kB
Buffers: shared hit=702 read=25024
Worker 0: Sort Method: quicksort Memory: 25kB
Worker 1: Sort Method: quicksort Memory: 25kB
-> Parallel Seq Scan on messages (cost=0.00..32987.62 rows=58 width=176) (actual time=12.630..13.319 rows=59 loops=3)
Filter: ((chat_id = '00000000-0000-7000-8000-000000000032'::uuid) AND (ROW(created_at, id) > ROW('2026-01-27 23:37:55.298126+00'::timestamp with time zone, '00000032-0000-7000-8002-000000000630'::uuid)))
Rows Removed by Filter: 333272
Buffers: shared hit=672 read=25024
Planning Time: 0.067 ms
Execution Time: 15.485 ms
=== none | chat_50 (1761 сообщений) | offset_deep | тёплый кэш
Limit (cost=32063.42..32063.54 rows=1 width=176) (actual time=15.830..16.873 rows=51 loops=1)
Buffers: shared hit=760 read=25024
-> Gather Merge (cost=31930.41..32063.42 rows=1140 width=176) (actual time=15.600..16.837 rows=1635 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=760 read=25024
-> Sort (cost=30930.39..30931.81 rows=570 width=176) (actual time=14.374..14.389 rows=587 loops=3)
Sort Key: created_at, id
Sort Method: quicksort Memory: 185kB
Buffers: shared hit=760 read=25024
Worker 0: Sort Method: quicksort Memory: 186kB
Worker 1: Sort Method: quicksort Memory: 157kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=570 width=176) (actual time=11.973..14.250 rows=587 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Rows Removed by Filter: 332744
Buffers: shared hit=672 read=25024
Planning Time: 0.096 ms
Execution Time: 16.898 ms
=== none | smallest (36 сообщений) | first | тёплый кэш
Limit (cost=31906.17..31912.12 rows=51 width=176) (actual time=13.734..14.652 rows=36 loops=1)
Buffers: shared hit=760 read=25024
-> Gather Merge (cost=31906.17..31920.63 rows=124 width=176) (actual time=13.733..14.648 rows=36 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=760 read=25024
-> Sort (cost=30906.14..30906.30 rows=62 width=176) (actual time=12.758..12.758 rows=12 loops=3)
Sort Key: created_at, id
Sort Method: quicksort Memory: 26kB
Buffers: shared hit=760 read=25024
Worker 0: Sort Method: quicksort Memory: 25kB
Worker 1: Sort Method: quicksort Memory: 32kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=62 width=176) (actual time=12.709..12.709 rows=12 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Rows Removed by Filter: 333319
Buffers: shared hit=672 read=25024
Planning Time: 0.066 ms
Execution Time: 14.661 ms
=== none | smallest (36 сообщений) | keyset_deep | тёплый кэш
Limit (cost=33987.74..33989.37 rows=14 width=176) (actual time=15.901..16.837 rows=4 loops=1)
Buffers: shared hit=702 read=25024
-> Gather Merge (cost=33987.74..33989.37 rows=14 width=176) (actual time=15.900..16.836 rows=4 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=702 read=25024
-> Sort (cost=32987.71..32987.73 rows=7 width=176) (actual time=14.760..14.760 rows=1 loops=3)
Sort Key: created_at, id
Sort Method: quicksort Memory: 25kB
Buffers: shared hit=702 read=25024
Worker 0: Sort Method: quicksort Memory: 26kB
Worker 1: Sort Method: quicksort Memory: 25kB
-> Parallel Seq Scan on messages (cost=0.00..32987.62 rows=7 width=176) (actual time=14.740..14.741 rows=1 loops=3)
Filter: ((chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid) AND (ROW(created_at, id) > ROW('2026-01-27 16:00:00+00'::timestamp with time zone, '000003e8-0000-7000-8002-000000000020'::uuid)))
Rows Removed by Filter: 333330
Buffers: shared hit=672 read=25024
Planning Time: 0.106 ms
Execution Time: 16.849 ms
=== none | smallest (36 сообщений) | offset_deep | тёплый кэш
Limit (cost=31909.90..31915.85 rows=51 width=176) (actual time=13.819..14.716 rows=4 loops=1)
Buffers: shared hit=760 read=25024
-> Gather Merge (cost=31906.17..31920.63 rows=124 width=176) (actual time=13.806..14.706 rows=36 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=760 read=25024
-> Sort (cost=30906.14..30906.30 rows=62 width=176) (actual time=12.679..12.679 rows=12 loops=3)
Sort Key: created_at, id
Sort Method: quicksort Memory: 26kB
Buffers: shared hit=760 read=25024
Worker 0: Sort Method: quicksort Memory: 25kB
Worker 1: Sort Method: quicksort Memory: 32kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=62 width=176) (actual time=12.627..12.628 rows=12 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Rows Removed by Filter: 333319
Buffers: shared hit=672 read=25024
Planning Time: 0.075 ms
Execution Time: 14.727 ms
=== chat_id | largest (284708 сообщений) | first | тёплый кэш
Limit (cost=16437.64..16443.59 rows=51 width=176) (actual time=10.754..11.724 rows=51 loops=1)
Buffers: shared hit=7866
-> Gather Merge (cost=16437.64..43836.62 rows=234832 width=176) (actual time=10.754..11.722 rows=51 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=7866
-> Sort (cost=15437.62..15731.16 rows=117416 width=176) (actual time=9.806..9.807 rows=51 loops=3)
Sort Key: created_at, id
Sort Method: top-N heapsort Memory: 38kB
Buffers: shared hit=7866
Worker 0: Sort Method: top-N heapsort Memory: 38kB
Worker 1: Sort Method: top-N heapsort Memory: 38kB
-> Parallel Index Scan using track_chat_idx on messages (cost=0.42..11520.37 rows=117416 width=176) (actual time=0.006..5.561 rows=94903 loops=3)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Buffers: shared hit=7836
Planning Time: 0.068 ms
Execution Time: 11.738 ms
=== chat_id | largest (284708 сообщений) | keyset_deep | тёплый кэш
Limit (cost=13498.08..13504.03 rows=51 width=176) (actual time=6.926..7.877 rows=51 loops=1)
Buffers: shared hit=7848
-> Gather Merge (cost=13498.08..16230.14 rows=23416 width=176) (actual time=6.925..7.874 rows=51 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=7848
-> Sort (cost=12498.05..12527.32 rows=11708 width=176) (actual time=5.778..5.779 rows=51 loops=3)
Sort Key: created_at, id
Sort Method: top-N heapsort Memory: 38kB
Buffers: shared hit=7848
Worker 0: Sort Method: top-N heapsort Memory: 38kB
Worker 1: Sort Method: top-N heapsort Memory: 38kB
-> Parallel Index Scan using track_chat_idx on messages (cost=0.42..12107.45 rows=11708 width=176) (actual time=4.661..5.364 rows=9490 loops=3)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Filter: (ROW(created_at, id) > ROW('2026-01-27 23:59:58.179187+00'::timestamp with time zone, '00000001-0000-7000-8002-00000003e8ed'::uuid))
Rows Removed by Filter: 85412
Buffers: shared hit=7818
Planning Time: 0.087 ms
Execution Time: 7.900 ms
=== chat_id | largest (284708 сообщений) | offset_deep | тёплый кэш
Limit (cost=59841.05..59841.16 rows=1 width=176) (actual time=56.297..59.389 rows=51 loops=1)
Buffers: shared hit=7849, temp read=6290 written=6665
-> Gather Merge (cost=32442.07..59841.05 rows=234832 width=176) (actual time=20.056..54.066 rows=256288 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=7849, temp read=6290 written=6665
-> Sort (cost=31442.04..31735.58 rows=117416 width=176) (actual time=18.834..24.515 rows=85603 loops=3)
Sort Key: created_at, id
Sort Method: external merge Disk: 19728kB
Buffers: shared hit=7849, temp read=6290 written=6665
Worker 0: Sort Method: external merge Disk: 16616kB
Worker 1: Sort Method: external merge Disk: 16824kB
-> Parallel Index Scan using track_chat_idx on messages (cost=0.42..11520.37 rows=117416 width=176) (actual time=0.014..6.727 rows=94903 loops=3)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Buffers: shared hit=7819
Planning Time: 0.104 ms
Execution Time: 60.257 ms
=== chat_id | chat_50 (1761 сообщений) | first | тёплый кэш
Limit (cost=139.43..139.56 rows=51 width=176) (actual time=0.197..0.200 rows=51 loops=1)
Buffers: shared hit=50
-> Sort (cost=139.43..143.60 rows=1667 width=176) (actual time=0.197..0.198 rows=51 loops=1)
Sort Key: created_at, id
Sort Method: top-N heapsort Memory: 38kB
Buffers: shared hit=50
-> Index Scan using track_chat_idx on messages (cost=0.42..83.82 rows=1667 width=176) (actual time=0.010..0.109 rows=1761 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Buffers: shared hit=50
Planning Time: 0.064 ms
Execution Time: 0.211 ms
=== chat_id | chat_50 (1761 сообщений) | keyset_deep | тёплый кэш
Limit (cost=97.73..97.85 rows=51 width=176) (actual time=0.095..0.098 rows=51 loops=1)
Buffers: shared hit=50
-> Sort (cost=97.73..98.14 rows=167 width=176) (actual time=0.095..0.097 rows=51 loops=1)
Sort Key: created_at, id
Sort Method: top-N heapsort Memory: 38kB
Buffers: shared hit=50
-> Index Scan using track_chat_idx on messages (cost=0.42..92.15 rows=167 width=176) (actual time=0.072..0.083 rows=177 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Filter: (ROW(created_at, id) > ROW('2026-01-27 23:37:55.298126+00'::timestamp with time zone, '00000032-0000-7000-8002-000000000630'::uuid))
Rows Removed by Filter: 1584
Buffers: shared hit=50
Planning Time: 0.024 ms
Execution Time: 0.105 ms
=== chat_id | chat_50 (1761 сообщений) | offset_deep | тёплый кэш
Limit (cost=176.99..177.12 rows=51 width=176) (actual time=0.300..0.304 rows=51 loops=1)
Buffers: shared hit=50
-> Sort (cost=173.03..177.20 rows=1667 width=176) (actual time=0.232..0.270 rows=1635 loops=1)
Sort Key: created_at, id
Sort Method: quicksort Memory: 503kB
Buffers: shared hit=50
-> Index Scan using track_chat_idx on messages (cost=0.42..83.82 rows=1667 width=176) (actual time=0.004..0.086 rows=1761 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Buffers: shared hit=50
Planning Time: 0.022 ms
Execution Time: 0.320 ms
=== chat_id | smallest (36 сообщений) | first | тёплый кэш
Limit (cost=19.13..19.25 rows=51 width=176) (actual time=0.012..0.014 rows=36 loops=1)
Buffers: shared hit=5
-> Sort (cost=19.13..19.50 rows=151 width=176) (actual time=0.011..0.012 rows=36 loops=1)
Sort Key: created_at, id
Sort Method: quicksort Memory: 34kB
Buffers: shared hit=5
-> Index Scan using track_chat_idx on messages (cost=0.42..14.09 rows=151 width=176) (actual time=0.005..0.007 rows=36 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Buffers: shared hit=5
Planning Time: 0.037 ms
Execution Time: 0.023 ms
=== chat_id | smallest (36 сообщений) | keyset_deep | тёплый кэш
Limit (cost=15.19..15.23 rows=17 width=176) (actual time=0.012..0.013 rows=4 loops=1)
Buffers: shared hit=5
-> Sort (cost=15.19..15.23 rows=17 width=176) (actual time=0.012..0.012 rows=4 loops=1)
Sort Key: created_at, id
Sort Method: quicksort Memory: 26kB
Buffers: shared hit=5
-> Index Scan using track_chat_idx on messages (cost=0.42..14.84 rows=17 width=176) (actual time=0.008..0.008 rows=4 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Filter: (ROW(created_at, id) > ROW('2026-01-27 16:00:00+00'::timestamp with time zone, '000003e8-0000-7000-8002-000000000020'::uuid))
Rows Removed by Filter: 32
Buffers: shared hit=5
Planning Time: 0.076 ms
Execution Time: 0.021 ms
=== chat_id | smallest (36 сообщений) | offset_deep | тёплый кэш
Limit (cost=19.63..19.76 rows=51 width=176) (actual time=0.017..0.018 rows=4 loops=1)
Buffers: shared hit=5
-> Sort (cost=19.55..19.93 rows=151 width=176) (actual time=0.016..0.017 rows=36 loops=1)
Sort Key: created_at, id
Sort Method: quicksort Memory: 34kB
Buffers: shared hit=5
-> Index Scan using track_chat_idx on messages (cost=0.42..14.09 rows=151 width=176) (actual time=0.008..0.010 rows=36 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Buffers: shared hit=5
Planning Time: 0.070 ms
Execution Time: 0.026 ms
=== created_at_id | largest (284708 сообщений) | first | тёплый кэш
Limit (cost=0.42..25.26 rows=51 width=176) (actual time=0.010..0.031 rows=51 loops=1)
Buffers: shared hit=113
-> Index Scan using track_time_idx on messages (cost=0.42..139575.12 rows=286631 width=176) (actual time=0.010..0.028 rows=51 loops=1)
Filter: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Rows Removed by Filter: 73
Buffers: shared hit=113
Planning Time: 0.053 ms
Execution Time: 0.039 ms
=== created_at_id | largest (284708 сообщений) | keyset_deep | тёплый кэш
Limit (cost=0.42..188.15 rows=51 width=176) (actual time=0.027..0.052 rows=51 loops=1)
Buffers: shared hit=251
-> Index Scan using track_time_idx on messages (cost=0.42..106136.95 rows=28835 width=176) (actual time=0.027..0.049 rows=51 loops=1)
Index Cond: (ROW(created_at, id) > ROW('2026-01-27 23:59:58.179187+00'::timestamp with time zone, '00000001-0000-7000-8002-00000003e8ed'::uuid))
Filter: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Rows Removed by Filter: 200
Buffers: shared hit=251
Planning Time: 0.035 ms
Execution Time: 0.058 ms
=== created_at_id | largest (284708 сообщений) | offset_deep | тёплый кэш
Limit (cost=80050.68..80050.80 rows=1 width=176) (actual time=59.207..60.934 rows=51 loops=1)
Buffers: shared hit=807 read=24977, temp read=6253 written=6661
-> Gather Merge (cost=52181.74..80050.68 rows=238860 width=176) (actual time=26.737..55.792 rows=256288 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=807 read=24977, temp read=6253 written=6661
-> Sort (cost=51181.71..51480.29 rows=119430 width=176) (actual time=25.560..31.143 rows=85575 loops=3)
Sort Key: created_at, id
Sort Method: external merge Disk: 18736kB
Buffers: shared hit=807 read=24977, temp read=6253 written=6661
Worker 0: Sort Method: external merge Disk: 16960kB
Worker 1: Sort Method: external merge Disk: 17440kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=119430 width=176) (actual time=0.016..14.329 rows=94903 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Rows Removed by Filter: 238428
Buffers: shared hit=719 read=24977
Planning Time: 0.097 ms
Execution Time: 61.612 ms
=== created_at_id | chat_50 (1761 сообщений) | first | тёплый кэш
Limit (cost=0.42..3813.12 rows=51 width=176) (actual time=0.065..3.258 rows=51 loops=1)
Buffers: shared hit=28010
-> Index Scan using track_time_idx on messages (cost=0.42..139575.12 rows=1867 width=176) (actual time=0.065..3.254 rows=51 loops=1)
Filter: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Rows Removed by Filter: 28460
Buffers: shared hit=28010
Planning Time: 0.053 ms
Execution Time: 3.268 ms
=== created_at_id | chat_50 (1761 сообщений) | keyset_deep | тёплый кэш
Limit (cost=0.42..28646.45 rows=51 width=176) (actual time=0.099..3.240 rows=51 loops=1)
Buffers: shared hit=28414
-> Index Scan using track_time_idx on messages (cost=0.42..106159.22 rows=189 width=176) (actual time=0.099..3.236 rows=51 loops=1)
Index Cond: (ROW(created_at, id) > ROW('2026-01-27 23:37:55.298126+00'::timestamp with time zone, '00000032-0000-7000-8002-000000000630'::uuid))
Filter: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Rows Removed by Filter: 28907
Buffers: shared hit=28414
Planning Time: 0.038 ms
Execution Time: 3.251 ms
=== created_at_id | chat_50 (1761 сообщений) | offset_deep | тёплый кэш
Limit (cost=32123.22..32123.34 rows=1 width=176) (actual time=14.536..15.478 rows=51 loops=1)
Buffers: shared hit=2431 read=23353
-> Gather Merge (cost=31941.68..32123.22 rows=1556 width=176) (actual time=14.355..15.443 rows=1635 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=2431 read=23353
-> Sort (cost=30941.65..30943.60 rows=778 width=176) (actual time=13.244..13.265 rows=587 loops=3)
Sort Key: created_at, id
Sort Method: quicksort Memory: 185kB
Buffers: shared hit=2431 read=23353
Worker 0: Sort Method: quicksort Memory: 157kB
Worker 1: Sort Method: quicksort Memory: 186kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=778 width=176) (actual time=10.936..13.123 rows=587 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Rows Removed by Filter: 332744
Buffers: shared hit=2343 read=23353
Planning Time: 0.099 ms
Execution Time: 15.503 ms
=== created_at_id | smallest (36 сообщений) | first | тёплый кэш
Limit (cost=31906.17..31912.12 rows=51 width=176) (actual time=13.930..15.035 rows=36 loops=1)
Buffers: shared hit=760 read=25024
-> Gather Merge (cost=31906.17..31920.63 rows=124 width=176) (actual time=13.929..15.033 rows=36 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=760 read=25024
-> Sort (cost=30906.14..30906.30 rows=62 width=176) (actual time=12.920..12.920 rows=12 loops=3)
Sort Key: created_at, id
Sort Method: quicksort Memory: 32kB
Buffers: shared hit=760 read=25024
Worker 0: Sort Method: quicksort Memory: 26kB
Worker 1: Sort Method: quicksort Memory: 25kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=62 width=176) (actual time=12.870..12.871 rows=12 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Rows Removed by Filter: 333319
Buffers: shared hit=672 read=25024
Planning Time: 0.091 ms
Execution Time: 15.047 ms
=== created_at_id | smallest (36 сообщений) | keyset_deep | тёплый кэш
Limit (cost=30560.11..30561.75 rows=14 width=176) (actual time=5.528..6.445 rows=4 loops=1)
Buffers: shared hit=4524
-> Gather Merge (cost=30560.11..30561.75 rows=14 width=176) (actual time=5.528..6.444 rows=4 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=4524
-> Sort (cost=29560.09..29560.11 rows=7 width=176) (actual time=4.643..4.643 rows=1 loops=3)
Sort Key: created_at, id
Sort Method: quicksort Memory: 25kB
Buffers: shared hit=4524
Worker 0: Sort Method: quicksort Memory: 25kB
Worker 1: Sort Method: quicksort Memory: 26kB
-> Parallel Bitmap Heap Scan on messages (cost=3049.84..29559.99 rows=7 width=176) (actual time=4.627..4.627 rows=1 loops=3)
Recheck Cond: (ROW(created_at, id) > ROW('2026-01-27 16:00:00+00'::timestamp with time zone, '000003e8-0000-7000-8002-000000000020'::uuid))
Filter: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Rows Removed by Filter: 37186
Heap Blocks: exact=1618
Buffers: shared hit=4494
-> Bitmap Index Scan on track_time_idx (cost=0.00..3049.84 rows=111655 width=0) (actual time=3.125..3.125 rows=111561 loops=1)
Index Cond: (ROW(created_at, id) > ROW('2026-01-27 16:00:00+00'::timestamp with time zone, '000003e8-0000-7000-8002-000000000020'::uuid))
Buffers: shared hit=553
Planning Time: 0.069 ms
Execution Time: 6.464 ms
=== created_at_id | smallest (36 сообщений) | offset_deep | тёплый кэш
Limit (cost=31909.90..31915.85 rows=51 width=176) (actual time=14.001..15.088 rows=4 loops=1)
Buffers: shared hit=4605 read=21179
-> Gather Merge (cost=31906.17..31920.63 rows=124 width=176) (actual time=13.998..15.086 rows=36 loops=1)
Workers Planned: 2
Workers Launched: 2
Buffers: shared hit=4605 read=21179
-> Sort (cost=30906.14..30906.30 rows=62 width=176) (actual time=13.028..13.029 rows=12 loops=3)
Sort Key: created_at, id
Sort Method: quicksort Memory: 25kB
Buffers: shared hit=4605 read=21179
Worker 0: Sort Method: quicksort Memory: 32kB
Worker 1: Sort Method: quicksort Memory: 26kB
-> Parallel Seq Scan on messages (cost=0.00..30904.30 rows=62 width=176) (actual time=12.975..12.976 rows=12 loops=3)
Filter: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Rows Removed by Filter: 333319
Buffers: shared hit=4517 read=21179
Planning Time: 0.090 ms
Execution Time: 15.100 ms
=== chat_id_created_at_id | largest (284708 сообщений) | first | тёплый кэш
Limit (cost=0.42..11.49 rows=51 width=176) (actual time=0.008..0.014 rows=51 loops=1)
Buffers: shared hit=5
-> Index Scan using messages_history_idx on messages (cost=0.42..62439.90 rows=287698 width=176) (actual time=0.008..0.011 rows=51 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Buffers: shared hit=5
Planning Time: 0.035 ms
Execution Time: 0.020 ms
=== chat_id_created_at_id | largest (284708 сообщений) | keyset_deep | тёплый кэш
Limit (cost=0.42..61.18 rows=51 width=176) (actual time=0.009..0.014 rows=51 loops=1)
Buffers: shared hit=5
-> Index Scan using messages_history_idx on messages (cost=0.42..33769.77 rows=28348 width=176) (actual time=0.008..0.011 rows=51 loops=1)
Index Cond: ((chat_id = '00000000-0000-7000-8000-000000000001'::uuid) AND (ROW(created_at, id) > ROW('2026-01-27 23:59:58.179187+00'::timestamp with time zone, '00000001-0000-7000-8002-00000003e8ed'::uuid)))
Buffers: shared hit=5
Planning Time: 0.050 ms
Execution Time: 0.023 ms
=== chat_id_created_at_id | largest (284708 сообщений) | offset_deep | тёплый кэш
Limit (cost=55611.87..55622.94 rows=51 width=176) (actual time=21.642..21.647 rows=51 loops=1)
Buffers: shared hit=9012
-> Index Scan using messages_history_idx on messages (cost=0.42..62439.90 rows=287698 width=176) (actual time=0.011..16.618 rows=256288 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000001'::uuid)
Buffers: shared hit=9012
Planning Time: 0.078 ms
Execution Time: 21.666 ms
=== chat_id_created_at_id | chat_50 (1761 сообщений) | first | тёплый кэш
Limit (cost=0.42..90.76 rows=51 width=176) (actual time=0.006..0.011 rows=51 loops=1)
Buffers: shared hit=5
-> Index Scan using messages_history_idx on messages (cost=0.42..2303.01 rows=1300 width=176) (actual time=0.006..0.008 rows=51 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Buffers: shared hit=5
Planning Time: 0.034 ms
Execution Time: 0.018 ms
=== chat_id_created_at_id | chat_50 (1761 сообщений) | keyset_deep | тёплый кэш
Limit (cost=0.42..93.83 rows=51 width=176) (actual time=0.006..0.013 rows=51 loops=1)
Buffers: shared hit=6
-> Index Scan using messages_history_idx on messages (cost=0.42..236.70 rows=129 width=176) (actual time=0.006..0.011 rows=51 loops=1)
Index Cond: ((chat_id = '00000000-0000-7000-8000-000000000032'::uuid) AND (ROW(created_at, id) > ROW('2026-01-27 23:37:55.298126+00'::timestamp with time zone, '00000032-0000-7000-8002-000000000630'::uuid)))
Buffers: shared hit=6
Planning Time: 0.049 ms
Execution Time: 0.020 ms
=== chat_id_created_at_id | chat_50 (1761 сообщений) | offset_deep | тёплый кэш
Limit (cost=2303.01..2304.79 rows=1 width=176) (actual time=0.158..0.164 rows=51 loops=1)
Buffers: shared hit=64
-> Index Scan using messages_history_idx on messages (cost=0.42..2303.01 rows=1300 width=176) (actual time=0.005..0.125 rows=1635 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-000000000032'::uuid)
Buffers: shared hit=64
Planning Time: 0.031 ms
Execution Time: 0.170 ms
=== chat_id_created_at_id | smallest (36 сообщений) | first | тёплый кэш
Limit (cost=0.42..94.71 rows=51 width=176) (actual time=0.006..0.010 rows=36 loops=1)
Buffers: shared hit=5
-> Index Scan using messages_history_idx on messages (cost=0.42..272.19 rows=147 width=176) (actual time=0.006..0.009 rows=36 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Buffers: shared hit=5
Planning Time: 0.044 ms
Execution Time: 0.016 ms
=== chat_id_created_at_id | smallest (36 сообщений) | keyset_deep | тёплый кэш
Limit (cost=0.42..35.00 rows=16 width=176) (actual time=0.005..0.006 rows=4 loops=1)
Buffers: shared hit=4
-> Index Scan using messages_history_idx on messages (cost=0.42..35.00 rows=16 width=176) (actual time=0.005..0.006 rows=4 loops=1)
Index Cond: ((chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid) AND (ROW(created_at, id) > ROW('2026-01-27 16:00:00+00'::timestamp with time zone, '000003e8-0000-7000-8002-000000000020'::uuid)))
Buffers: shared hit=4
Planning Time: 0.039 ms
Execution Time: 0.012 ms
=== chat_id_created_at_id | smallest (36 сообщений) | offset_deep | тёплый кэш
Limit (cost=59.58..153.87 rows=51 width=176) (actual time=0.008..0.009 rows=4 loops=1)
Buffers: shared hit=5
-> Index Scan using messages_history_idx on messages (cost=0.42..272.19 rows=147 width=176) (actual time=0.005..0.007 rows=36 loops=1)
Index Cond: (chat_id = '00000000-0000-7000-8000-0000000003e8'::uuid)
Buffers: shared hit=5
Planning Time: 0.040 ms
Execution Time: 0.015 ms
+608
View File
@@ -0,0 +1,608 @@
{
"meta": {
"date": "2026-10-28T17:28:48.636Z",
"commit": "6468ee2",
"postgres": "17.11"
},
"method": "время начала и конца pg_dump — clock_timestamp() PostgreSQL источника, теми же часами, что created_at маркеров",
"runs": [
{
"messages": 100011,
"attempt": 1,
"dataset": {
"messages": 100011,
"chats": 1000,
"zipf_s": 1.3,
"largest": 28471,
"chat_50": 176,
"smallest": 4,
"largest_share": 0.2847,
"top10_share": 0.6507,
"table_bytes": 20922368,
"seed_seconds": 1.1
},
"dump": {
"file": "backups/track-100011.dump",
"bytes": 1685570,
"dump_seconds": 0.15,
"dump_started": "2026-10-28T17:28:52.450145+00:00",
"dump_finished": "2026-10-28T17:28:52.597283+00:00"
},
"instance": {
"volume": "mtusi2026lab2_pgrestore",
"volume_created": "2026-10-28T17:28:53Z"
},
"restore": {
"pre-data_seconds": 0.2,
"data_seconds": 0.35,
"post-data_seconds": 0.22,
"new_instance_seconds": 1.3,
"verify_seconds": 0.19,
"rto_seconds": 2.26
},
"checks": {
"users": true,
"chats": true,
"chat_members": true,
"messages": true,
"migrations": true,
"per_chat_counts_md5": true,
"history_md5_largest": true,
"history_md5_chat_50": true,
"history_md5_smallest": true,
"sample_rows": true,
"sample_md5": true,
"indexes": true,
"constraints": true
},
"all_checks_passed": true,
"source": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 100011,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "b06aba9e2766adec5cc81ea748132e15",
"history_md5_largest": "b810fd78d33a0ba7063788f5a0575bac",
"history_md5_chat_50": "5a9e32b500653af6d41a2e9e601ea154",
"history_md5_smallest": "c1827adf4c8667bc1706113288d6bef6",
"sample_rows": 90,
"sample_md5": "3f0fbfe474b498ff751f283bc2171c62",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 75,
"last_marker_at": "2026-10-28T17:28:53.231617+00:00"
},
"restored": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 100011,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "b06aba9e2766adec5cc81ea748132e15",
"history_md5_largest": "b810fd78d33a0ba7063788f5a0575bac",
"history_md5_chat_50": "5a9e32b500653af6d41a2e9e601ea154",
"history_md5_smallest": "c1827adf4c8667bc1706113288d6bef6",
"sample_rows": 90,
"sample_md5": "3f0fbfe474b498ff751f283bc2171c62",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 41,
"last_marker_at": "2026-10-28T17:28:52.449345+00:00"
},
"rpo": {
"markers_in_source": 75,
"markers_in_backup": 41,
"markers_lost": 34,
"markers_lost_while_dump_was_running": 6,
"last_marker_in_backup": "2026-10-28T17:28:52.449345+00:00",
"dump_started": "2026-10-28T17:28:52.450145+00:00",
"dump_finished": "2026-10-28T17:28:52.597283+00:00"
}
},
{
"messages": 100011,
"attempt": 2,
"dataset": {
"messages": 100011,
"chats": 1000,
"zipf_s": 1.3,
"largest": 28471,
"chat_50": 176,
"smallest": 4,
"largest_share": 0.2847,
"top10_share": 0.6507,
"table_bytes": 20922368,
"seed_seconds": 1.1
},
"dump": {
"file": "backups/track-100011.dump",
"bytes": 1685752,
"dump_seconds": 0.15,
"dump_started": "2026-10-28T17:28:57.537217+00:00",
"dump_finished": "2026-10-28T17:28:57.682906+00:00"
},
"instance": {
"volume": "mtusi2026lab2_pgrestore",
"volume_created": "2026-10-28T17:28:59Z"
},
"restore": {
"pre-data_seconds": 0.14,
"data_seconds": 0.35,
"post-data_seconds": 0.23,
"new_instance_seconds": 1.26,
"verify_seconds": 0.19,
"rto_seconds": 2.17
},
"checks": {
"users": true,
"chats": true,
"chat_members": true,
"messages": true,
"migrations": true,
"per_chat_counts_md5": true,
"history_md5_largest": true,
"history_md5_chat_50": true,
"history_md5_smallest": true,
"sample_rows": true,
"sample_md5": true,
"indexes": true,
"constraints": true
},
"all_checks_passed": true,
"source": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 100011,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "b06aba9e2766adec5cc81ea748132e15",
"history_md5_largest": "b810fd78d33a0ba7063788f5a0575bac",
"history_md5_chat_50": "5a9e32b500653af6d41a2e9e601ea154",
"history_md5_smallest": "c1827adf4c8667bc1706113288d6bef6",
"sample_rows": 90,
"sample_md5": "3f0fbfe474b498ff751f283bc2171c62",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 77,
"last_marker_at": "2026-10-28T17:28:58.333567+00:00"
},
"restored": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 100011,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "b06aba9e2766adec5cc81ea748132e15",
"history_md5_largest": "b810fd78d33a0ba7063788f5a0575bac",
"history_md5_chat_50": "5a9e32b500653af6d41a2e9e601ea154",
"history_md5_smallest": "c1827adf4c8667bc1706113288d6bef6",
"sample_rows": 90,
"sample_md5": "3f0fbfe474b498ff751f283bc2171c62",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 43,
"last_marker_at": "2026-10-28T17:28:57.534265+00:00"
},
"rpo": {
"markers_in_source": 77,
"markers_in_backup": 43,
"markers_lost": 34,
"markers_lost_while_dump_was_running": 6,
"last_marker_in_backup": "2026-10-28T17:28:57.534265+00:00",
"dump_started": "2026-10-28T17:28:57.537217+00:00",
"dump_finished": "2026-10-28T17:28:57.682906+00:00"
}
},
{
"messages": 100011,
"attempt": 3,
"dataset": {
"messages": 100011,
"chats": 1000,
"zipf_s": 1.3,
"largest": 28471,
"chat_50": 176,
"smallest": 4,
"largest_share": 0.2847,
"top10_share": 0.6507,
"table_bytes": 20922368,
"seed_seconds": 1.1
},
"dump": {
"file": "backups/track-100011.dump",
"bytes": 1685825,
"dump_seconds": 0.15,
"dump_started": "2026-10-28T17:29:02.671832+00:00",
"dump_finished": "2026-10-28T17:29:02.819966+00:00"
},
"instance": {
"volume": "mtusi2026lab2_pgrestore",
"volume_created": "2026-10-28T17:29:04Z"
},
"restore": {
"pre-data_seconds": 0.16,
"data_seconds": 0.34,
"post-data_seconds": 0.22,
"new_instance_seconds": 1.26,
"verify_seconds": 0.19,
"rto_seconds": 2.17
},
"checks": {
"users": true,
"chats": true,
"chat_members": true,
"messages": true,
"migrations": true,
"per_chat_counts_md5": true,
"history_md5_largest": true,
"history_md5_chat_50": true,
"history_md5_smallest": true,
"sample_rows": true,
"sample_md5": true,
"indexes": true,
"constraints": true
},
"all_checks_passed": true,
"source": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 100011,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "b06aba9e2766adec5cc81ea748132e15",
"history_md5_largest": "b810fd78d33a0ba7063788f5a0575bac",
"history_md5_chat_50": "5a9e32b500653af6d41a2e9e601ea154",
"history_md5_smallest": "c1827adf4c8667bc1706113288d6bef6",
"sample_rows": 90,
"sample_md5": "3f0fbfe474b498ff751f283bc2171c62",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 76,
"last_marker_at": "2026-10-28T17:29:03.454521+00:00"
},
"restored": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 100011,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "b06aba9e2766adec5cc81ea748132e15",
"history_md5_largest": "b810fd78d33a0ba7063788f5a0575bac",
"history_md5_chat_50": "5a9e32b500653af6d41a2e9e601ea154",
"history_md5_smallest": "c1827adf4c8667bc1706113288d6bef6",
"sample_rows": 90,
"sample_md5": "3f0fbfe474b498ff751f283bc2171c62",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 43,
"last_marker_at": "2026-10-28T17:29:02.670566+00:00"
},
"rpo": {
"markers_in_source": 76,
"markers_in_backup": 43,
"markers_lost": 33,
"markers_lost_while_dump_was_running": 7,
"last_marker_in_backup": "2026-10-28T17:29:02.670566+00:00",
"dump_started": "2026-10-28T17:29:02.671832+00:00",
"dump_finished": "2026-10-28T17:29:02.819966+00:00"
}
},
{
"messages": 999993,
"attempt": 1,
"dataset": {
"messages": 999993,
"chats": 1000,
"zipf_s": 1.3,
"largest": 284708,
"chat_50": 1761,
"smallest": 36,
"largest_share": 0.2847,
"top10_share": 0.6508,
"table_bytes": 210591744,
"seed_seconds": 8.6
},
"dump": {
"file": "backups/track-999993.dump",
"bytes": 15400057,
"dump_seconds": 1.03,
"dump_started": "2026-10-28T17:29:17.903031+00:00",
"dump_finished": "2026-10-28T17:29:18.937636+00:00"
},
"instance": {
"volume": "mtusi2026lab2_pgrestore",
"volume_created": "2026-10-28T17:29:20Z"
},
"restore": {
"pre-data_seconds": 0.17,
"data_seconds": 2.16,
"post-data_seconds": 0.89,
"new_instance_seconds": 1.27,
"verify_seconds": 0.83,
"rto_seconds": 5.32
},
"checks": {
"users": true,
"chats": true,
"chat_members": true,
"messages": true,
"migrations": true,
"per_chat_counts_md5": true,
"history_md5_largest": true,
"history_md5_chat_50": true,
"history_md5_smallest": true,
"sample_rows": true,
"sample_md5": true,
"indexes": true,
"constraints": true
},
"all_checks_passed": true,
"source": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 999993,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "9c9de2270a5df6c52d3c9fa78e788d52",
"history_md5_largest": "d2e65041f85c2b3918b6ed41f90ae912",
"history_md5_chat_50": "507411ae207ce077b612fb47ddd69de8",
"history_md5_smallest": "9c119064d444208cdec773d9dd82c9d6",
"sample_rows": 1005,
"sample_md5": "7ce2113e18546b9191eda7c66c5fcf10",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 118,
"last_marker_at": "2026-10-28T17:29:19.571073+00:00"
},
"restored": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 999993,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "9c9de2270a5df6c52d3c9fa78e788d52",
"history_md5_largest": "d2e65041f85c2b3918b6ed41f90ae912",
"history_md5_chat_50": "507411ae207ce077b612fb47ddd69de8",
"history_md5_smallest": "9c119064d444208cdec773d9dd82c9d6",
"sample_rows": 1005,
"sample_md5": "7ce2113e18546b9191eda7c66c5fcf10",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 42,
"last_marker_at": "2026-10-28T17:29:17.887529+00:00"
},
"rpo": {
"markers_in_source": 118,
"markers_in_backup": 42,
"markers_lost": 76,
"markers_lost_while_dump_was_running": 48,
"last_marker_in_backup": "2026-10-28T17:29:17.887529+00:00",
"dump_started": "2026-10-28T17:29:17.903031+00:00",
"dump_finished": "2026-10-28T17:29:18.937636+00:00"
}
},
{
"messages": 999993,
"attempt": 2,
"dataset": {
"messages": 999993,
"chats": 1000,
"zipf_s": 1.3,
"largest": 284708,
"chat_50": 1761,
"smallest": 36,
"largest_share": 0.2847,
"top10_share": 0.6508,
"table_bytes": 210591744,
"seed_seconds": 8.6
},
"dump": {
"file": "backups/track-999993.dump",
"bytes": 15400357,
"dump_seconds": 1.04,
"dump_started": "2026-10-28T17:29:27.895177+00:00",
"dump_finished": "2026-10-28T17:29:28.932480+00:00"
},
"instance": {
"volume": "mtusi2026lab2_pgrestore",
"volume_created": "2026-10-28T17:29:31Z"
},
"restore": {
"pre-data_seconds": 0.16,
"data_seconds": 2.17,
"post-data_seconds": 0.91,
"new_instance_seconds": 1.27,
"verify_seconds": 0.84,
"rto_seconds": 5.35
},
"checks": {
"users": true,
"chats": true,
"chat_members": true,
"messages": true,
"migrations": true,
"per_chat_counts_md5": true,
"history_md5_largest": true,
"history_md5_chat_50": true,
"history_md5_smallest": true,
"sample_rows": true,
"sample_md5": true,
"indexes": true,
"constraints": true
},
"all_checks_passed": true,
"source": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 999993,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "9c9de2270a5df6c52d3c9fa78e788d52",
"history_md5_largest": "d2e65041f85c2b3918b6ed41f90ae912",
"history_md5_chat_50": "507411ae207ce077b612fb47ddd69de8",
"history_md5_smallest": "9c119064d444208cdec773d9dd82c9d6",
"sample_rows": 1005,
"sample_md5": "7ce2113e18546b9191eda7c66c5fcf10",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 118,
"last_marker_at": "2026-10-28T17:29:29.591525+00:00"
},
"restored": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 999993,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "9c9de2270a5df6c52d3c9fa78e788d52",
"history_md5_largest": "d2e65041f85c2b3918b6ed41f90ae912",
"history_md5_chat_50": "507411ae207ce077b612fb47ddd69de8",
"history_md5_smallest": "9c119064d444208cdec773d9dd82c9d6",
"sample_rows": 1005,
"sample_md5": "7ce2113e18546b9191eda7c66c5fcf10",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 44,
"last_marker_at": "2026-10-28T17:29:27.894289+00:00"
},
"rpo": {
"markers_in_source": 118,
"markers_in_backup": 44,
"markers_lost": 74,
"markers_lost_while_dump_was_running": 46,
"last_marker_in_backup": "2026-10-28T17:29:27.894289+00:00",
"dump_started": "2026-10-28T17:29:27.895177+00:00",
"dump_finished": "2026-10-28T17:29:28.932480+00:00"
}
},
{
"messages": 999993,
"attempt": 3,
"dataset": {
"messages": 999993,
"chats": 1000,
"zipf_s": 1.3,
"largest": 284708,
"chat_50": 1761,
"smallest": 36,
"largest_share": 0.2847,
"top10_share": 0.6508,
"table_bytes": 210591744,
"seed_seconds": 8.6
},
"dump": {
"file": "backups/track-999993.dump",
"bytes": 15400375,
"dump_seconds": 1.05,
"dump_started": "2026-10-28T17:29:38.014765+00:00",
"dump_finished": "2026-10-28T17:29:39.062119+00:00"
},
"instance": {
"volume": "mtusi2026lab2_pgrestore",
"volume_created": "2026-10-28T17:29:41Z"
},
"restore": {
"pre-data_seconds": 0.16,
"data_seconds": 2.13,
"post-data_seconds": 0.91,
"new_instance_seconds": 1.27,
"verify_seconds": 0.84,
"rto_seconds": 5.31
},
"checks": {
"users": true,
"chats": true,
"chat_members": true,
"messages": true,
"migrations": true,
"per_chat_counts_md5": true,
"history_md5_largest": true,
"history_md5_chat_50": true,
"history_md5_smallest": true,
"sample_rows": true,
"sample_md5": true,
"indexes": true,
"constraints": true
},
"all_checks_passed": true,
"source": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 999993,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "9c9de2270a5df6c52d3c9fa78e788d52",
"history_md5_largest": "d2e65041f85c2b3918b6ed41f90ae912",
"history_md5_chat_50": "507411ae207ce077b612fb47ddd69de8",
"history_md5_smallest": "9c119064d444208cdec773d9dd82c9d6",
"sample_rows": 1005,
"sample_md5": "7ce2113e18546b9191eda7c66c5fcf10",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 118,
"last_marker_at": "2026-10-28T17:29:39.704206+00:00"
},
"restored": {
"users": 2000,
"chats": 1000,
"chat_members": 2000,
"messages": 999993,
"migrations": "0001_init:9a13618f078a",
"per_chat_counts_md5": "9c9de2270a5df6c52d3c9fa78e788d52",
"history_md5_largest": "d2e65041f85c2b3918b6ed41f90ae912",
"history_md5_chat_50": "507411ae207ce077b612fb47ddd69de8",
"history_md5_smallest": "9c119064d444208cdec773d9dd82c9d6",
"sample_rows": 1005,
"sample_md5": "7ce2113e18546b9191eda7c66c5fcf10",
"indexes": "chat_members_pkey,chat_members_user_idx,chats_pkey,messages_history_idx,messages_pkey,schema_migrations_pkey,sessions_pkey,sessions_user_idx,users_pkey,users_username_key",
"constraints": 19,
"markers": 43,
"last_marker_at": "2026-10-28T17:29:38.013596+00:00"
},
"rpo": {
"markers_in_source": 118,
"markers_in_backup": 43,
"markers_lost": 75,
"markers_lost_while_dump_was_running": 47,
"last_marker_in_backup": "2026-10-28T17:29:38.013596+00:00",
"dump_started": "2026-10-28T17:29:38.014765+00:00",
"dump_finished": "2026-10-28T17:29:39.062119+00:00"
}
}
],
"summary": [
{
"messages": 100011,
"repeats": 3,
"rto_median_seconds": 2.17,
"rto_range_seconds": [
2.17,
2.26
],
"new_instance_median_seconds": 1.26,
"all_checks_passed": true,
"markers_lost_while_dump_was_running": [
6,
6,
7
]
},
{
"messages": 999993,
"repeats": 3,
"rto_median_seconds": 5.32,
"rto_range_seconds": [
5.31,
5.35
],
"new_instance_median_seconds": 1.27,
"all_checks_passed": true,
"markers_lost_while_dump_was_running": [
48,
46,
47
]
}
]
}
+66
View File
@@ -0,0 +1,66 @@
date: 2026-10-28T17:18:31.130Z commit: 6468ee2 17.11
dataset: {"messages": 999993, "chats": 1000, "zipf_s": 1.3, "largest": 284708, "chat_50": 1761, "smallest": 36, "largest_share": 0.2847, "top10_share": 0.6508, "table_bytes": 210591744, "seed_seconds": 8.1}
variant | chat | query | warm median ms | cold median ms | hit/read (cold) | rows scanned | plan
none | largest | first | 21.986 | 19.778 | 81/25703 | 999993 | Limit > Gather Merge > Sort > Seq Scan
none | largest | keyset_deep | 17.603 | 16.681 | 28/25698 | 999993 | Limit > Gather Merge > Sort > Seq Scan
none | largest | offset_deep | 61.335 | 58.804 | 80/25704 | 999993 | Limit > Gather Merge > Sort > Seq Scan
none | chat_50 | first | 14.505 | 14.59 | 80/25704 | 999993 | Limit > Gather Merge > Sort > Seq Scan
none | chat_50 | keyset_deep | 15.863 | 16.096 | 28/25698 | 999993 | Limit > Gather Merge > Sort > Seq Scan
none | chat_50 | offset_deep | 16.791 | 16.125 | 81/25703 | 999993 | Limit > Gather Merge > Sort > Seq Scan
none | smallest | first | 14.383 | 15.032 | 80/25704 | 999993 | Limit > Gather Merge > Sort > Seq Scan
none | smallest | keyset_deep | 16.15 | 16.268 | 28/25698 | 999993 | Limit > Gather Merge > Sort > Seq Scan
none | smallest | offset_deep | 14.286 | 14.403 | 81/25703 | 999993 | Limit > Gather Merge > Sort > Seq Scan
chat_id | largest | first | 12.189 | 16.475 | 259/7608 | 284709 | Limit > Gather Merge > Sort > Index Scan(track_chat_idx)
chat_id | largest | keyset_deep | 8.294 | 12.737 | 255/7606 | 284706 | Limit > Gather Merge > Sort > Index Scan(track_chat_idx)
chat_id | largest | offset_deep | 55.767 | 63.201 | 240/7606 | 284709 | Limit > Gather Merge > Sort > Index Scan(track_chat_idx)
chat_id | chat_50 | first | 0.185 | 0.276 | 0/50 | 1761 | Limit > Sort > Index Scan(track_chat_idx)
chat_id | chat_50 | keyset_deep | 0.12 | 0.211 | 0/50 | 1761 | Limit > Sort > Index Scan(track_chat_idx)
chat_id | chat_50 | offset_deep | 0.344 | 0.447 | 0/50 | 1761 | Limit > Sort > Index Scan(track_chat_idx)
chat_id | smallest | first | 0.024 | 0.05 | 0/5 | 36 | Limit > Sort > Index Scan(track_chat_idx)
chat_id | smallest | keyset_deep | 0.016 | 0.034 | 0/5 | 36 | Limit > Sort > Index Scan(track_chat_idx)
chat_id | smallest | offset_deep | 0.018 | 0.037 | 0/5 | 36 | Limit > Sort > Index Scan(track_chat_idx)
created_at_id | largest | first | 0.035 | 0.092 | 88/25 | 124 | Limit > Index Scan(track_time_idx)
created_at_id | largest | keyset_deep | 0.065 | 0.325 | 103/148 | 251 | Limit > Index Scan(track_time_idx)
created_at_id | largest | offset_deep | 63.071 | 63.074 | 80/25704 | 999993 | Limit > Gather Merge > Sort > Seq Scan
created_at_id | chat_50 | first | 3.133 | 6.748 | 26118/1892 | 28511 | Limit > Index Scan(track_time_idx)
created_at_id | chat_50 | keyset_deep | 3.226 | 7.116 | 26501/1913 | 28958 | Limit > Index Scan(track_time_idx)
created_at_id | chat_50 | offset_deep | 15.902 | 14.655 | 79/25705 | 999993 | Limit > Gather Merge > Sort > Seq Scan
created_at_id | smallest | first | 14.654 | 14.474 | 80/25704 | 999993 | Limit > Gather Merge > Sort > Seq Scan
created_at_id | smallest | keyset_deep | 6.563 | 10.028 | 28/4496 | 223122 | Limit > Gather Merge > Sort > Bitmap Heap Scan > Bitmap Index Scan(track_time_idx)
created_at_id | smallest | offset_deep | 15.407 | 14.45 | 81/25703 | 999993 | Limit > Gather Merge > Sort > Seq Scan
chat_id_created_at_id | largest | first | 0.022 | 0.036 | 0/5 | 51 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | largest | keyset_deep | 0.024 | 0.035 | 0/5 | 51 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | largest | offset_deep | 19.956 | 33.396 | 559/8453 | 256288 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | chat_50 | first | 0.019 | 0.03 | 0/5 | 51 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | chat_50 | keyset_deep | 0.021 | 0.038 | 0/6 | 51 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | chat_50 | offset_deep | 0.157 | 0.25 | 7/57 | 1635 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | smallest | first | 0.017 | 0.03 | 0/5 | 36 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | smallest | keyset_deep | 0.012 | 0.024 | 0/4 | 4 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | smallest | offset_deep | 0.017 | 0.028 | 0/5 | 36 | Limit > Index Scan(messages_history_idx)
order | variant | commit | build s | table MB | indexes MB | tps median [min..max] | latency ms | WAL bytes/insert | WAL records/insert | FPI/insert | postgres CPU % | postgres MiB
1 | none | sync | 0.0 | 200.8 | 30.1 | 9455.4 [9314.0..9502.3] | 0.423 | 1511 | 6.7 | 0.128 | 272.13 | 281.6
1 | none | async | 0.0 | 200.8 | 30.1 | 12680.5 [12393.0..12819.5] | 0.315 | 1205 | 6.05 | 0.096 | 353.0 | 187.6
2 | chat_id | sync | 0.27 | 200.8 | 44.6 | 9233.4 [7941.2..9603.8] | 0.433 | 1588 | 7.06 | 0.135 | 273.39 | 188.1
2 | chat_id | async | 0.27 | 200.8 | 44.6 | 12496.8 [10742.6..12721.2] | 0.32 | 1303 | 7.04 | 0.1 | 352.39 | 189.5
3 | created_at_id | sync | 0.28 | 200.8 | 76.4 | 9179.6 [9055.4..9539.9] | 0.436 | 1586 | 7.04 | 0.132 | 273.37 | 188.5
3 | created_at_id | async | 0.28 | 200.8 | 76.4 | 12461.2 [12429.2..12625.5] | 0.321 | 1304 | 7.04 | 0.098 | 352.1 | 187.0
4 | chat_id_created_at_id | sync | 0.42 | 200.8 | 94.0 | 9112.6 [8820.8..9447.6] | 0.439 | 1644 | 7.03 | 0.146 | 275.45 | 187.1
4 | chat_id_created_at_id | async | 0.42 | 200.8 | 94.0 | 12443.6 [12368.3..12483.2] | 0.321 | 1365 | 7.04 | 0.11 | 351.74 | 189.5
5 | none | sync | 0.0 | 200.8 | 37.8 | 9345.7 [9278.8..9600.6] | 0.428 | 1483 | 6.03 | 0.13 | 273.66 | 185.0
5 | none | async | 0.0 | 200.8 | 37.8 | 12550.5 [12436.8..12612.4] | 0.319 | 1216 | 6.06 | 0.097 | 353.1 | 184.5
variant | chat | plan_cache_mode | median ms | plan
chat_id | largest | force_custom_plan | 12.96 | Limit > Gather Merge > Sort > Index Scan(track_chat_idx)
chat_id | largest | force_generic_plan | 28.128 | Limit > Sort > Index Scan(track_chat_idx)
chat_id | smallest | force_custom_plan | 0.029 | Limit > Sort > Index Scan(track_chat_idx)
chat_id | smallest | force_generic_plan | 0.026 | Limit > Sort > Index Scan(track_chat_idx)
created_at_id | largest | force_custom_plan | 0.034 | Limit > Index Scan(track_time_idx)
created_at_id | largest | force_generic_plan | 0.039 | Limit > Index Scan(track_time_idx)
created_at_id | smallest | force_custom_plan | 14.9 | Limit > Gather Merge > Sort > Seq Scan
created_at_id | smallest | force_generic_plan | 156.475 | Limit > Index Scan(track_time_idx)
chat_id_created_at_id | largest | force_custom_plan | 0.023 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | largest | force_generic_plan | 0.022 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | smallest | force_custom_plan | 0.021 | Limit > Index Scan(messages_history_idx)
chat_id_created_at_id | smallest | force_generic_plan | 0.015 | Limit > Index Scan(messages_history_idx)