Skip to content

perf(db): drop duplicate reward disbursement index#909

Merged
raymondjacobson merged 1 commit into
mainfrom
codex/db-audit-drop-duplicate-reward-disbursement-index
Jun 8, 2026
Merged

perf(db): drop duplicate reward disbursement index#909
raymondjacobson merged 1 commit into
mainfrom
codex/db-audit-drop-duplicate-reward-disbursement-index

Conversation

@raymondjacobson

Copy link
Copy Markdown
Member

Summary

  • drops sol_reward_disbursements_challenge_specifier_idx concurrently when present
  • keeps sol_reward_disbursements_challenge_idx, which has the same (challenge_id, specifier) key

Production evidence

  • the database audit found sol_reward_disbursements_challenge_specifier_idx duplicating the checked-in sol_reward_disbursements_challenge_idx
  • both indexes support the same challenge/specifier lookups, so keeping both adds write and vacuum overhead without improving read plans

Verification

  • migration review only; SQL is DROP INDEX CONCURRENTLY IF EXISTS
  • no application code changed

@raymondjacobson raymondjacobson merged commit 1cb71c3 into main Jun 8, 2026
5 checks passed
@raymondjacobson raymondjacobson deleted the codex/db-audit-drop-duplicate-reward-disbursement-index branch June 8, 2026 22:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant