isle.pizza/server/migrations
Christian Semmler 8205f56a76
Index memory_completions(event_id, completed_at) for delete reconcile
The account-deletion reconcile in account.ts uses a correlated subquery
to pick the latest-per-event row from memory_completions. Without an
index whose leading column is event_id the inner subquery falls back to
scanning sqlite_autoindex_memory_completions_1, making the reconcile
O(rows^2) — observed cost in production was ~171k rows read for one
deletion against ~407 rows. With this covering index the inner becomes
a seek and the reconcile drops to ~rows*log(rows).
2026-05-05 16:06:07 -07:00
..
0001_initial.sql Add multiplayer frontend updates (#30) 2026-04-05 17:13:23 +02:00
0002_drop_char_columns.sql Add multiplayer frontend updates (#30) 2026-04-05 17:13:23 +02:00
0003_object_id_to_anim_index.sql Add multiplayer frontend updates (#30) 2026-04-05 17:13:23 +02:00
0004_add_language.sql Add multiplayer frontend updates (#30) 2026-04-05 17:13:23 +02:00
0005_crash_reports.sql Add multiplayer frontend updates (#30) 2026-04-05 17:13:23 +02:00
0006_cloud_storage.sql Add multiplayer frontend updates (#30) 2026-04-05 17:13:23 +02:00
0007_memory_events.sql Optimize latest memory queries (#35) 2026-05-02 23:15:28 +02:00
0008_memory_completions_event_index.sql Index memory_completions(event_id, completed_at) for delete reconcile 2026-05-05 16:06:07 -07:00