Skip to content

Conversation

chrisjm
Copy link
Collaborator

@chrisjm chrisjm commented Aug 21, 2025

📃 Description

This is an attempt to help with the Slow DB errors in Sentry. Early benchmarking shows promise so I figure it's worth a shot.

🪵 Changelog

➕ Added

  • DB Migration: Indices on name, city, state_province, country, and postal_code (we may not need postal_code, but unless we run into index size issues, it should be fine to keep)
  • Console: perf:gauntlet to benchmark the changes

✏️ Changed

  • Updated the Brewery Filters to only match the prefix for the column value, ex., city LIKE 'san%' since wrapping with % removes SQLite performance optimizations. SQLite - LIKE optimization. I kept name the same since it is more practical to not know the full name.

📷 Screenshots

With Indices and LIKE '%pattern%'

CleanShot 2025-08-20 at 17 23 42

With Indices and LIKE 'pattern%'

CleanShot 2025-08-20 at 17 27 35

@chrisjm chrisjm requested a review from alexjustesen as a code owner August 21, 2025 00:42
@chrisjm chrisjm assigned chrisjm and unassigned chrisjm Aug 21, 2025
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