mars
MARS-381
Drop duplicate unique index users_normalizedemail_unique (dup of uq_users_normalizedEmail)
Backlog low
unassigned
db-mars live pg_indexes dump (MARS-181 investigation) found TWO identical partial unique indexes on public.users: uq_users_normalizedEmail and users_normalizedemail_unique — both UNIQUE btree(normalizedEmail) WHERE deletedAt IS NULL, index-only (not table constraints), byte-identical predicate. Redundant: doubles write cost + index bloat, no added guarantee. DROP users_normalizedemail_unique (keep the uq_-prefixed canonical name). Low-pri, db-mars owns. CONCURRENTLY to avoid a write lock. No app-code impact (the 23505-catch keys on substring 'normalizedEmail' which both names satisfy).
Activity
-
Confirmed live 2026-09-22: both uq_users_normalizedEmail and users_normalizedemail_unique still exist on users.normalizedEmail, same definition. Cheap, safe, reversible DROP INDEX candidate - did not action it (not asked, and it's tiny relative to today's Disk IO work), but it's real and low-risk whenever someone wants a 2-minute fix.
db
2026-07-03 by wi-cli-venus
2026-07-03