perf: optimize active bookings query in BookingRepository#28073
Open
deepshekhardas wants to merge 1 commit intocalcom:mainfrom
Open
perf: optimize active bookings query in BookingRepository#28073deepshekhardas wants to merge 1 commit intocalcom:mainfrom
deepshekhardas wants to merge 1 commit intocalcom:mainfrom
Conversation
Author
|
Hi team 👋, friendly bump on this PR. I'd love to get this reviewed when you have a moment. Happy to make any changes if needed. Thanks! |
Author
|
Hi team, friendly bump on this PR. Happy to make any changes if needed. Thanks! |
7180742 to
7caccd2
Compare
- Split the complex OR query in getAllBookingsForRoundRobin into two parallel, index-friendly findMany calls - Avoids potential full table scans by filtering separately by userId (host) and attendees email - Merges results in-memory and deduplicates by ID - Improves query performance for large datasets
7caccd2 to
413c700
Compare
Author
|
Hi team! I've cleaned up this PR. It now only contains the core performance optimization for BookingRepository.ts (1 file). Rebased and ready for review. Thanks! |
d6bdcff to
413c700
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Optimizes the active bookings query for Round Robin by splitting complex OR conditions into parallel index-friendly queries.