Index update, Phase 1: Add large_user_postcode flag and index#610
Merged
Conversation
c04a9ee to
a5beca3
Compare
sihugh
approved these changes
Apr 23, 2025
- relevant index used by postcode collection worker will be checking for active and small postcodes (ie retired and large_user_postcode = false), and ordered by updated_at. - Default to large_user_postcode: false, set to true in a rake task from the existing ONSPD data. Only ONSPD records will ever be large_user_postcode: true, so we only need to check them, but they must be set before the code to use them is added, and since this will timeout a migration, we have to do it as a 2-phase deploy (1: migrate, update data, 2: update code.)
a5beca3 to
12b2953
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.
Related to: #572
...because the migration times out due to data fixup, releasing as 2 phases - this phase will add the index and fix up the data, the next phase will bring in the code once all data is fixed up correctly.
https://trello.com/c/Pf89f3wr/350-improve-worker-cpu-usage-on-locations-api, Jira issue PNP-6398
Follow these steps if you are doing a Rails upgrade.