Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf: Add index to EventType for parentId #17049

Merged
merged 1 commit into from
Oct 10, 2024

Conversation

keithwillcode
Copy link
Contributor

What does this PR do?

We run lots of queries that filter by the parentId column in the EventType table, resulting in Seq Scans. We can improve read perf by having this index.

Mandatory Tasks (DO NOT REMOVE)

  • I have self-reviewed the code (A decent size PR without self-review might be rejected).
  • N/A - I have updated the developer docs in /docs if this PR makes changes that would require a documentation change. If N/A, write N/A here and check the checkbox.
  • I confirm automated tests are in place that prove my fix is effective or that my feature works.

How should this be tested?

  • Ensure the migration runs fine on qa/prod
  • Analyze query performance before/after

@keithwillcode keithwillcode self-assigned this Oct 10, 2024
@graphite-app graphite-app bot requested a review from a team October 10, 2024 17:24
@github-actions github-actions bot added the ❗️ migrations contains migration files label Oct 10, 2024
@keithwillcode keithwillcode added core area: core, team members only foundation labels Oct 10, 2024
@dosubot dosubot bot added the performance area: performance, page load, slow, slow endpoints, loading screen, unresponsive label Oct 10, 2024
Copy link

graphite-app bot commented Oct 10, 2024

Graphite Automations

"Add foundation team as reviewer" took an action on this PR • (10/10/24)

1 reviewer was added to this PR based on Keith Williams's automation.

"Add ready-for-e2e label" took an action on this PR • (10/10/24)

1 label was added to this PR based on Keith Williams's automation.

Copy link

vercel bot commented Oct 10, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
cal ⬜️ Ignored (Inspect) Oct 10, 2024 5:27pm
calcom-web-canary ⬜️ Ignored (Inspect) Oct 10, 2024 5:27pm

Copy link
Member

@zomars zomars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@PeerRich PeerRich enabled auto-merge (squash) October 10, 2024 17:40
@PeerRich PeerRich merged commit ef88eff into main Oct 10, 2024
54 of 77 checks passed
@PeerRich PeerRich deleted the perf/event-type-index-parent-id branch October 10, 2024 17:46
Copy link
Contributor

E2E results are ready!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core area: core, team members only foundation ❗️ migrations contains migration files performance area: performance, page load, slow, slow endpoints, loading screen, unresponsive ready-for-e2e
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants