[FLOW-28] Rebuilt Bucket Query Views to be faster and more accurate #131
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.
This PR creates a new Hasura migration that updates the review bucket views (
course_easy_buckets
,course_useful_buckets
,prof_clear_buckets
andprof_engaging_buckets
) to only include reviews that have:liked
valuecourse_comment
orprof_comment
course_easy
for course easy buckets)It also adds the same materialized pattern and indexing implemented in #51 for the review bucket views for more optimized retrieval.
PR Summary Generated with AI Copilot:
This pull request updates the review bucket views and materialized views to include only reviews with a rating and either a professor or course rating. The most important changes include dropping and recreating views and materialized views, updating the conditions for review inclusion, and adding necessary indexes and triggers.
Changes to views and materialized views:
course_easy_buckets
,course_useful_buckets
,prof_clear_buckets
, andprof_engaging_buckets
. [1] [2]liked
value and either acourse_comment
orprof_comment
.Indexes and triggers:
review
table.