Skip to content

feat: add missing indexes, upgrade drizzle#1309

Merged
StarpTech merged 8 commits into
mainfrom
dustin/add-missing-indexes
Oct 28, 2024
Merged

feat: add missing indexes, upgrade drizzle#1309
StarpTech merged 8 commits into
mainfrom
dustin/add-missing-indexes

Conversation

@StarpTech

@StarpTech StarpTech commented Oct 25, 2024

Copy link
Copy Markdown
Contributor

Motivation and Context

CleanShot 2024-10-25 at 15 58 57@2x

This PR adds the following improvements:

  • Postgres doesn't add automatically indexes to foreign keys. This PR adds missing indexes for all foreign keys to improve performance. Ref
  • Add missing indexes for columns that are queried frequently based on query performance analysis of GCP e.g. audit logs table.
  • Upgrade drizzle to latest version. This implied to not pass 0 as limit to the query builder because 0 means no results. Before the upgrade 0 was ignored.
  • We were able to get rid of our custom JSON types. Drizzle inserts them now correctly.

Checklist

  • I have discussed my proposed changes in an issue and have received approval to proceed.
  • I have followed the coding standards of the project.
  • Tests or benchmarks have been added or updated.
  • Documentation has been updated on https://github.com/wundergraph/cosmo-docs.
  • I have read the Contributors Guide.

@github-actions github-actions Bot removed the router label Oct 28, 2024
@StarpTech StarpTech merged commit 5b022e5 into main Oct 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants