forked from mtusi2026/mtusi2026lab2
2643 lines
78 KiB
Markdown
2643 lines
78 KiB
Markdown
# Трек 2: чтение и стоимость записи
|
|
|
|
Дата сбора: `2026-10-01T17:33:15.537043+00:00`.
|
|
|
|
Команды выполняются в корне репозитория, Linux/WSL. Контекст Compose: `COMPOSE_PROJECT_NAME=messenger-evidence-final-20261001-02`, `COMPOSE_FILE=compose.yaml:src/experiments/evidence/compose.override.yaml`. Параметры стенда и запуск: [07-compose-secrets.md](07-compose-secrets.md).
|
|
|
|
### Ранее выполненный эксперимент
|
|
|
|
```sh
|
|
make track2-run RUN_ID=20261001-c
|
|
```
|
|
|
|
Сохранённый stdout завершённого прогона (локальный путь архива опущен):
|
|
|
|
```text
|
|
python3 src/experiments/track2/run.py run --run-id "20261001-c"
|
|
Starting isolated source database
|
|
Read measurements complete: base
|
|
Read measurements complete: covering
|
|
Creating backup and restoring into a new volume
|
|
PASS: messenger-track2-20261001-c; evidence: /mnt/c/projects/Highload-systems/mtusi2026lab2-fork/evidence/track2/20261001-c
|
|
```
|
|
|
|
Файл: [src/experiments/track2/run.py](../../src/experiments/track2/run.py).
|
|
|
|
Файл: [evidence/track2/20261001-c/commands.jsonl](../track2/20261001-c/commands.jsonl).
|
|
|
|
Файл: [evidence/track2/20261001-c/queries.sql](../track2/20261001-c/queries.sql).
|
|
|
|
### Сохранённый результат: `reads.json`
|
|
|
|
```json
|
|
[
|
|
{
|
|
"name": "read-base-large-first",
|
|
"median_ms": 0.111,
|
|
"min_ms": 0.093,
|
|
"max_ms": 0.155,
|
|
"scan": "Index Scan",
|
|
"index": "messages_history_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": null,
|
|
"shared_hit": 4,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-base-large-late",
|
|
"median_ms": 0.145,
|
|
"min_ms": 0.111,
|
|
"max_ms": 0.175,
|
|
"scan": "Index Scan",
|
|
"index": "messages_history_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": null,
|
|
"shared_hit": 6,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-base-large-offset",
|
|
"median_ms": 18.06,
|
|
"min_ms": 16.037,
|
|
"max_ms": 23.447,
|
|
"scan": "Index Scan",
|
|
"index": "messages_history_idx",
|
|
"scan_rows": 90050,
|
|
"heap_fetches": null,
|
|
"shared_hit": 1933,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-base-medium-first",
|
|
"median_ms": 0.162,
|
|
"min_ms": 0.112,
|
|
"max_ms": 0.216,
|
|
"scan": "Index Scan",
|
|
"index": "messages_history_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": null,
|
|
"shared_hit": 5,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-base-medium-late",
|
|
"median_ms": 0.158,
|
|
"min_ms": 0.123,
|
|
"max_ms": 0.321,
|
|
"scan": "Index Scan",
|
|
"index": "messages_history_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": null,
|
|
"shared_hit": 6,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-base-medium-offset",
|
|
"median_ms": 8.073,
|
|
"min_ms": 7.084,
|
|
"max_ms": 17.063,
|
|
"scan": "Bitmap Index Scan",
|
|
"index": "messages_history_idx",
|
|
"scan_rows": 15000,
|
|
"heap_fetches": null,
|
|
"shared_hit": 331,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-base-small-first",
|
|
"median_ms": 0.116,
|
|
"min_ms": 0.107,
|
|
"max_ms": 0.159,
|
|
"scan": "Index Scan",
|
|
"index": "messages_history_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": null,
|
|
"shared_hit": 5,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-base-small-late",
|
|
"median_ms": 0.122,
|
|
"min_ms": 0.111,
|
|
"max_ms": 0.149,
|
|
"scan": "Index Scan",
|
|
"index": "messages_history_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": null,
|
|
"shared_hit": 4,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-base-small-offset",
|
|
"median_ms": 2.94,
|
|
"min_ms": 2.443,
|
|
"max_ms": 3.45,
|
|
"scan": "Bitmap Index Scan",
|
|
"index": "messages_history_idx",
|
|
"scan_rows": 5000,
|
|
"heap_fetches": null,
|
|
"shared_hit": 118,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-covering-large-first",
|
|
"median_ms": 0.132,
|
|
"min_ms": 0.116,
|
|
"max_ms": 0.17,
|
|
"scan": "Index Only Scan",
|
|
"index": "messages_history_covering_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": 0,
|
|
"shared_hit": 4,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-covering-large-late",
|
|
"median_ms": 0.16,
|
|
"min_ms": 0.121,
|
|
"max_ms": 0.195,
|
|
"scan": "Index Only Scan",
|
|
"index": "messages_history_covering_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": 0,
|
|
"shared_hit": 5,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-covering-large-offset",
|
|
"median_ms": 19.628,
|
|
"min_ms": 17.441,
|
|
"max_ms": 22.872,
|
|
"scan": "Index Only Scan",
|
|
"index": "messages_history_covering_idx",
|
|
"scan_rows": 90050,
|
|
"heap_fetches": 0,
|
|
"shared_hit": 1237,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-covering-medium-first",
|
|
"median_ms": 0.249,
|
|
"min_ms": 0.13,
|
|
"max_ms": 0.51,
|
|
"scan": "Index Only Scan",
|
|
"index": "messages_history_covering_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": 0,
|
|
"shared_hit": 5,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-covering-medium-late",
|
|
"median_ms": 0.138,
|
|
"min_ms": 0.123,
|
|
"max_ms": 0.313,
|
|
"scan": "Index Only Scan",
|
|
"index": "messages_history_covering_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": 0,
|
|
"shared_hit": 5,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-covering-medium-offset",
|
|
"median_ms": 2.403,
|
|
"min_ms": 2.201,
|
|
"max_ms": 2.951,
|
|
"scan": "Index Only Scan",
|
|
"index": "messages_history_covering_idx",
|
|
"scan_rows": 13550,
|
|
"heap_fetches": 0,
|
|
"shared_hit": 190,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-covering-small-first",
|
|
"median_ms": 0.136,
|
|
"min_ms": 0.127,
|
|
"max_ms": 0.193,
|
|
"scan": "Index Only Scan",
|
|
"index": "messages_history_covering_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": 0,
|
|
"shared_hit": 5,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-covering-small-late",
|
|
"median_ms": 0.143,
|
|
"min_ms": 0.128,
|
|
"max_ms": 0.237,
|
|
"scan": "Index Only Scan",
|
|
"index": "messages_history_covering_idx",
|
|
"scan_rows": 50,
|
|
"heap_fetches": 0,
|
|
"shared_hit": 5,
|
|
"shared_read": 0
|
|
},
|
|
{
|
|
"name": "read-covering-small-offset",
|
|
"median_ms": 1.002,
|
|
"min_ms": 0.814,
|
|
"max_ms": 1.345,
|
|
"scan": "Index Only Scan",
|
|
"index": "messages_history_covering_idx",
|
|
"scan_rows": 4550,
|
|
"heap_fetches": 0,
|
|
"shared_hit": 66,
|
|
"shared_read": 0
|
|
}
|
|
]
|
|
```
|
|
|
|
### Сохранённый результат: `writes.json`
|
|
|
|
```json
|
|
[
|
|
{
|
|
"variant": "none",
|
|
"median_ms": 34.362,
|
|
"min_ms": 31.466,
|
|
"max_ms": 35.912,
|
|
"median_wal_bytes": 2319396,
|
|
"index_bytes": 417792
|
|
},
|
|
{
|
|
"variant": "base",
|
|
"median_ms": 48.76,
|
|
"min_ms": 43.652,
|
|
"max_ms": 62.255,
|
|
"median_wal_bytes": 3343720,
|
|
"index_bytes": 1024000
|
|
},
|
|
{
|
|
"variant": "covering",
|
|
"median_ms": 46.544,
|
|
"min_ms": 45.157,
|
|
"max_ms": 51.712,
|
|
"median_wal_bytes": 3897536,
|
|
"index_bytes": 1572864
|
|
}
|
|
]
|
|
```
|
|
|
|
### Сохранённый результат: `sizes.json`
|
|
|
|
```json
|
|
{
|
|
"base": {
|
|
"table_bytes": 14049280,
|
|
"index_bytes": 7086080
|
|
},
|
|
"covering": {
|
|
"table_bytes": 14049280,
|
|
"index_bytes": 13574144
|
|
}
|
|
}
|
|
```
|
|
|
|
### Сохранённый результат: `read-base-large-late.json`
|
|
|
|
```json
|
|
[
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 21.32,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.07,
|
|
"Actual Total Time": 0.084,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 3480.77,
|
|
"Plan Rows": 8324,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.069,
|
|
"Actual Total Time": 0.079,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 106,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.516,
|
|
"Triggers": [],
|
|
"Execution Time": 0.172
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 21.32,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.062,
|
|
"Actual Total Time": 0.075,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 3480.77,
|
|
"Plan Rows": 8324,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.061,
|
|
"Actual Total Time": 0.07,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 106,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.433,
|
|
"Triggers": [],
|
|
"Execution Time": 0.128
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 21.32,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.058,
|
|
"Actual Total Time": 0.077,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 3480.77,
|
|
"Plan Rows": 8324,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.057,
|
|
"Actual Total Time": 0.071,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 106,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.511,
|
|
"Triggers": [],
|
|
"Execution Time": 0.145
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 21.32,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.048,
|
|
"Actual Total Time": 0.061,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 3480.77,
|
|
"Plan Rows": 8324,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.047,
|
|
"Actual Total Time": 0.056,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 106,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.397,
|
|
"Triggers": [],
|
|
"Execution Time": 0.112
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 21.32,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.048,
|
|
"Actual Total Time": 0.061,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 3480.77,
|
|
"Plan Rows": 8324,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.047,
|
|
"Actual Total Time": 0.056,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 106,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.38,
|
|
"Triggers": [],
|
|
"Execution Time": 0.111
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 21.32,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.075,
|
|
"Actual Total Time": 0.11,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 3480.77,
|
|
"Plan Rows": 8324,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.074,
|
|
"Actual Total Time": 0.104,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 106,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.565,
|
|
"Triggers": [],
|
|
"Execution Time": 0.175
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 21.32,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.066,
|
|
"Actual Total Time": 0.081,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 3480.77,
|
|
"Plan Rows": 8324,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.065,
|
|
"Actual Total Time": 0.076,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 6,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 106,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.643,
|
|
"Triggers": [],
|
|
"Execution Time": 0.155
|
|
}
|
|
]
|
|
```
|
|
|
|
### Сохранённый результат: `read-base-large-offset.json`
|
|
|
|
```json
|
|
[
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 7594.28,
|
|
"Total Cost": 7598.5,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 15.987,
|
|
"Actual Total Time": 16.0,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 8454.92,
|
|
"Plan Rows": 100200,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.035,
|
|
"Actual Total Time": 12.893,
|
|
"Actual Rows": 90050,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "(chat_id = '22222222-2222-4222-8222-222222222221'::uuid)",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 107,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.384,
|
|
"Triggers": [],
|
|
"Execution Time": 16.037
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 7594.28,
|
|
"Total Cost": 7598.5,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 18.273,
|
|
"Actual Total Time": 18.288,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 8454.92,
|
|
"Plan Rows": 100200,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.043,
|
|
"Actual Total Time": 14.993,
|
|
"Actual Rows": 90050,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "(chat_id = '22222222-2222-4222-8222-222222222221'::uuid)",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 107,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.614,
|
|
"Triggers": [],
|
|
"Execution Time": 18.342
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 7594.28,
|
|
"Total Cost": 7598.5,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 17.393,
|
|
"Actual Total Time": 17.409,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 8454.92,
|
|
"Plan Rows": 100200,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.042,
|
|
"Actual Total Time": 13.994,
|
|
"Actual Rows": 90050,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "(chat_id = '22222222-2222-4222-8222-222222222221'::uuid)",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 107,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.514,
|
|
"Triggers": [],
|
|
"Execution Time": 17.451
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 7594.28,
|
|
"Total Cost": 7598.5,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 18.011,
|
|
"Actual Total Time": 18.023,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 8454.92,
|
|
"Plan Rows": 100200,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.034,
|
|
"Actual Total Time": 14.458,
|
|
"Actual Rows": 90050,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "(chat_id = '22222222-2222-4222-8222-222222222221'::uuid)",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 107,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.389,
|
|
"Triggers": [],
|
|
"Execution Time": 18.06
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 7594.28,
|
|
"Total Cost": 7598.5,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 17.534,
|
|
"Actual Total Time": 17.547,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 8454.92,
|
|
"Plan Rows": 100200,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.035,
|
|
"Actual Total Time": 14.086,
|
|
"Actual Rows": 90050,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "(chat_id = '22222222-2222-4222-8222-222222222221'::uuid)",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 107,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.377,
|
|
"Triggers": [],
|
|
"Execution Time": 17.581
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 7594.28,
|
|
"Total Cost": 7598.5,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 18.384,
|
|
"Actual Total Time": 18.396,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 8454.92,
|
|
"Plan Rows": 100200,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.05,
|
|
"Actual Total Time": 15.14,
|
|
"Actual Rows": 90050,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "(chat_id = '22222222-2222-4222-8222-222222222221'::uuid)",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 107,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.837,
|
|
"Triggers": [],
|
|
"Execution Time": 18.436
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 7594.28,
|
|
"Total Cost": 7598.5,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 23.358,
|
|
"Actual Total Time": 23.371,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 8454.92,
|
|
"Plan Rows": 100200,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.078,
|
|
"Actual Total Time": 20.196,
|
|
"Actual Rows": 90050,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "(chat_id = '22222222-2222-4222-8222-222222222221'::uuid)",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Shared Hit Blocks": 1933,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 107,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 1.034,
|
|
"Triggers": [],
|
|
"Execution Time": 23.447
|
|
}
|
|
]
|
|
```
|
|
|
|
### Сохранённый результат: `read-covering-large-late.json`
|
|
|
|
```json
|
|
[
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 4.19,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.063,
|
|
"Actual Total Time": 0.086,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Only Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_covering_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 620.82,
|
|
"Plan Rows": 8220,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.062,
|
|
"Actual Total Time": 0.081,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Heap Fetches": 0,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 112,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.472,
|
|
"Triggers": [],
|
|
"Execution Time": 0.16
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 4.19,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.05,
|
|
"Actual Total Time": 0.093,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Only Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_covering_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 620.82,
|
|
"Plan Rows": 8220,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.049,
|
|
"Actual Total Time": 0.088,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Heap Fetches": 0,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 112,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.525,
|
|
"Triggers": [],
|
|
"Execution Time": 0.147
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 4.19,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.067,
|
|
"Actual Total Time": 0.088,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Only Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_covering_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 620.82,
|
|
"Plan Rows": 8220,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.066,
|
|
"Actual Total Time": 0.083,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Heap Fetches": 0,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 112,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.481,
|
|
"Triggers": [],
|
|
"Execution Time": 0.149
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 4.19,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.074,
|
|
"Actual Total Time": 0.123,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Only Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_covering_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 620.82,
|
|
"Plan Rows": 8220,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.073,
|
|
"Actual Total Time": 0.117,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Heap Fetches": 0,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 112,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.517,
|
|
"Triggers": [],
|
|
"Execution Time": 0.195
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 4.19,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.075,
|
|
"Actual Total Time": 0.104,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Only Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_covering_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 620.82,
|
|
"Plan Rows": 8220,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.074,
|
|
"Actual Total Time": 0.099,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Heap Fetches": 0,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 112,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.482,
|
|
"Triggers": [],
|
|
"Execution Time": 0.167
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 4.19,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.059,
|
|
"Actual Total Time": 0.077,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Only Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_covering_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 620.82,
|
|
"Plan Rows": 8220,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.058,
|
|
"Actual Total Time": 0.072,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Heap Fetches": 0,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 112,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.429,
|
|
"Triggers": [],
|
|
"Execution Time": 0.167
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Limit",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 4.19,
|
|
"Plan Rows": 50,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.049,
|
|
"Actual Total Time": 0.066,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Only Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "messages_history_covering_idx",
|
|
"Relation Name": "messages",
|
|
"Alias": "messages",
|
|
"Startup Cost": 0.42,
|
|
"Total Cost": 620.82,
|
|
"Plan Rows": 8220,
|
|
"Plan Width": 86,
|
|
"Actual Startup Time": 0.048,
|
|
"Actual Total Time": 0.062,
|
|
"Actual Rows": 50,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "((chat_id = '22222222-2222-4222-8222-222222222221'::uuid) AND (ROW(created_at, id) > ROW('2026-01-01 00:00:00.09+00'::timestamp with time zone, '1d664eb1-42e9-c630-c739-4623b08094d7'::uuid)))",
|
|
"Rows Removed by Index Recheck": 0,
|
|
"Heap Fetches": 0,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 112,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.393,
|
|
"Triggers": [],
|
|
"Execution Time": 0.121
|
|
}
|
|
]
|
|
```
|
|
|
|
### Сохранённый результат: `write-base.json`
|
|
|
|
```json
|
|
[
|
|
{
|
|
"Plan": {
|
|
"Node Type": "ModifyTable",
|
|
"Operation": "Insert",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_bench",
|
|
"Alias": "write_bench",
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 0,
|
|
"Plan Width": 0,
|
|
"Actual Startup Time": 52.204,
|
|
"Actual Total Time": 52.208,
|
|
"Actual Rows": 0,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 50217,
|
|
"Shared Read Blocks": 2,
|
|
"Shared Dirtied Blocks": 269,
|
|
"Shared Written Blocks": 269,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 30121,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 3343720,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Sort",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 3.989,
|
|
"Actual Total Time": 4.975,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Sort Key": [
|
|
"write_input.chat_id",
|
|
"write_input.created_at",
|
|
"write_input.id"
|
|
],
|
|
"Sort Method": "quicksort",
|
|
"Sort Space Used": 1478,
|
|
"Sort Space Type": "Memory",
|
|
"Shared Hit Blocks": 149,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Seq Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_input",
|
|
"Alias": "write_input",
|
|
"Startup Cost": 0.0,
|
|
"Total Cost": 243.0,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 0.015,
|
|
"Actual Total Time": 0.874,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 143,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 53,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.299,
|
|
"Triggers": [],
|
|
"Execution Time": 52.544
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "ModifyTable",
|
|
"Operation": "Insert",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_bench",
|
|
"Alias": "write_bench",
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 0,
|
|
"Plan Width": 0,
|
|
"Actual Startup Time": 48.414,
|
|
"Actual Total Time": 48.415,
|
|
"Actual Rows": 0,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 50217,
|
|
"Shared Read Blocks": 2,
|
|
"Shared Dirtied Blocks": 269,
|
|
"Shared Written Blocks": 269,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 30121,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 3343720,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Sort",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 4.824,
|
|
"Actual Total Time": 5.725,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Sort Key": [
|
|
"write_input.chat_id",
|
|
"write_input.created_at",
|
|
"write_input.id"
|
|
],
|
|
"Sort Method": "quicksort",
|
|
"Sort Space Used": 1478,
|
|
"Sort Space Type": "Memory",
|
|
"Shared Hit Blocks": 149,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Seq Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_input",
|
|
"Alias": "write_input",
|
|
"Startup Cost": 0.0,
|
|
"Total Cost": 243.0,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 0.017,
|
|
"Actual Total Time": 1.015,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 143,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 53,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.296,
|
|
"Triggers": [],
|
|
"Execution Time": 48.76
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "ModifyTable",
|
|
"Operation": "Insert",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_bench",
|
|
"Alias": "write_bench",
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 0,
|
|
"Plan Width": 0,
|
|
"Actual Startup Time": 49.348,
|
|
"Actual Total Time": 49.35,
|
|
"Actual Rows": 0,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 50217,
|
|
"Shared Read Blocks": 2,
|
|
"Shared Dirtied Blocks": 269,
|
|
"Shared Written Blocks": 269,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 30121,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 3343720,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Sort",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 3.756,
|
|
"Actual Total Time": 4.647,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Sort Key": [
|
|
"write_input.chat_id",
|
|
"write_input.created_at",
|
|
"write_input.id"
|
|
],
|
|
"Sort Method": "quicksort",
|
|
"Sort Space Used": 1478,
|
|
"Sort Space Type": "Memory",
|
|
"Shared Hit Blocks": 149,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Seq Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_input",
|
|
"Alias": "write_input",
|
|
"Startup Cost": 0.0,
|
|
"Total Cost": 243.0,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 0.017,
|
|
"Actual Total Time": 0.877,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 143,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 53,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.311,
|
|
"Triggers": [],
|
|
"Execution Time": 50.063
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "ModifyTable",
|
|
"Operation": "Insert",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_bench",
|
|
"Alias": "write_bench",
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 0,
|
|
"Plan Width": 0,
|
|
"Actual Startup Time": 43.243,
|
|
"Actual Total Time": 43.245,
|
|
"Actual Rows": 0,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 50217,
|
|
"Shared Read Blocks": 2,
|
|
"Shared Dirtied Blocks": 269,
|
|
"Shared Written Blocks": 269,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 30121,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 3343720,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Sort",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 3.984,
|
|
"Actual Total Time": 4.734,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Sort Key": [
|
|
"write_input.chat_id",
|
|
"write_input.created_at",
|
|
"write_input.id"
|
|
],
|
|
"Sort Method": "quicksort",
|
|
"Sort Space Used": 1478,
|
|
"Sort Space Type": "Memory",
|
|
"Shared Hit Blocks": 149,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Seq Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_input",
|
|
"Alias": "write_input",
|
|
"Startup Cost": 0.0,
|
|
"Total Cost": 243.0,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 0.018,
|
|
"Actual Total Time": 0.886,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 143,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 53,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.321,
|
|
"Triggers": [],
|
|
"Execution Time": 43.652
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "ModifyTable",
|
|
"Operation": "Insert",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_bench",
|
|
"Alias": "write_bench",
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 0,
|
|
"Plan Width": 0,
|
|
"Actual Startup Time": 43.769,
|
|
"Actual Total Time": 43.771,
|
|
"Actual Rows": 0,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 50217,
|
|
"Shared Read Blocks": 2,
|
|
"Shared Dirtied Blocks": 269,
|
|
"Shared Written Blocks": 269,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 30121,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 3343720,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Sort",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 3.701,
|
|
"Actual Total Time": 4.376,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Sort Key": [
|
|
"write_input.chat_id",
|
|
"write_input.created_at",
|
|
"write_input.id"
|
|
],
|
|
"Sort Method": "quicksort",
|
|
"Sort Space Used": 1478,
|
|
"Sort Space Type": "Memory",
|
|
"Shared Hit Blocks": 149,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Seq Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_input",
|
|
"Alias": "write_input",
|
|
"Startup Cost": 0.0,
|
|
"Total Cost": 243.0,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 0.015,
|
|
"Actual Total Time": 0.943,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 143,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 53,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.297,
|
|
"Triggers": [],
|
|
"Execution Time": 44.132
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "ModifyTable",
|
|
"Operation": "Insert",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_bench",
|
|
"Alias": "write_bench",
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 0,
|
|
"Plan Width": 0,
|
|
"Actual Startup Time": 61.93,
|
|
"Actual Total Time": 61.932,
|
|
"Actual Rows": 0,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 50217,
|
|
"Shared Read Blocks": 2,
|
|
"Shared Dirtied Blocks": 269,
|
|
"Shared Written Blocks": 269,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 30121,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 3343720,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Sort",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 3.563,
|
|
"Actual Total Time": 4.507,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Sort Key": [
|
|
"write_input.chat_id",
|
|
"write_input.created_at",
|
|
"write_input.id"
|
|
],
|
|
"Sort Method": "quicksort",
|
|
"Sort Space Used": 1478,
|
|
"Sort Space Type": "Memory",
|
|
"Shared Hit Blocks": 149,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Seq Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_input",
|
|
"Alias": "write_input",
|
|
"Startup Cost": 0.0,
|
|
"Total Cost": 243.0,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 0.016,
|
|
"Actual Total Time": 0.8,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 143,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 53,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.33,
|
|
"Triggers": [],
|
|
"Execution Time": 62.255
|
|
},
|
|
{
|
|
"Plan": {
|
|
"Node Type": "ModifyTable",
|
|
"Operation": "Insert",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_bench",
|
|
"Alias": "write_bench",
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 0,
|
|
"Plan Width": 0,
|
|
"Actual Startup Time": 47.142,
|
|
"Actual Total Time": 47.146,
|
|
"Actual Rows": 0,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 50217,
|
|
"Shared Read Blocks": 2,
|
|
"Shared Dirtied Blocks": 269,
|
|
"Shared Written Blocks": 269,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 30121,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 3343720,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Sort",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Startup Cost": 907.39,
|
|
"Total Cost": 932.39,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 3.688,
|
|
"Actual Total Time": 4.426,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Sort Key": [
|
|
"write_input.chat_id",
|
|
"write_input.created_at",
|
|
"write_input.id"
|
|
],
|
|
"Sort Method": "quicksort",
|
|
"Sort Space Used": 1478,
|
|
"Sort Space Type": "Memory",
|
|
"Shared Hit Blocks": 149,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Seq Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Async Capable": false,
|
|
"Relation Name": "write_input",
|
|
"Alias": "write_input",
|
|
"Startup Cost": 0.0,
|
|
"Total Cost": 243.0,
|
|
"Plan Rows": 10000,
|
|
"Plan Width": 85,
|
|
"Actual Startup Time": 0.017,
|
|
"Actual Total Time": 0.835,
|
|
"Actual Rows": 10000,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 143,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0,
|
|
"WAL Records": 0,
|
|
"WAL FPI": 0,
|
|
"WAL Bytes": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 53,
|
|
"Shared Read Blocks": 0,
|
|
"Shared Dirtied Blocks": 0,
|
|
"Shared Written Blocks": 0,
|
|
"Local Hit Blocks": 0,
|
|
"Local Read Blocks": 0,
|
|
"Local Dirtied Blocks": 0,
|
|
"Local Written Blocks": 0,
|
|
"Temp Read Blocks": 0,
|
|
"Temp Written Blocks": 0
|
|
},
|
|
"Planning Time": 0.449,
|
|
"Triggers": [],
|
|
"Execution Time": 47.509
|
|
}
|
|
]
|
|
```
|