-
Notifications
You must be signed in to change notification settings - Fork 196
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
feat(store-indexer): clean database if outdated #1984
Conversation
This reverts commit 6c9ddd6.
🦋 Changeset detectedLatest commit: 849ccd5 The changes in this PR will be included in the next version bump. This PR includes changesets to release 30 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
ac74c03
to
5570848
Compare
b169e0b
to
3a6d106
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
@@ -1,5 +1,4 @@ | |||
export * from "./buildTable"; | |||
export * from "./cleanDatabase"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for context, the postgres-decoded
version does not have a concept of cleaning the database if outdated correct?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is done at the store-indexer
level when the process starts up (rather than at the store sync level) and there's currently no binary/command for postgres-decoded
(can add that in a follow up)
detects if database is outdated (if
version
is present in theconfig
table and matches the version defined in code) and, if so, empties the database by deleting all MUD-related schemas and their tables