-
Notifications
You must be signed in to change notification settings - Fork 11.6k
indexer: drop df columns and refactoring #19308
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
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
3 Skipped Deployments
|
51a20ed
to
876bc4e
Compare
In order to drop a column, the process needs to take 2 releases, as described in https://www.notion.so/mystenlabs/Indexer-Release-Process-fdd71dffb3334b7c9ecd8df3cacbe5a7?pvs=4#2ad9f8dcd47241459ab700bdad13d863. |
@lxfind yes and for this specific change, the columns were always Nullable and we have removed the callsites from indexerJSON RPC and GraphQL on previous prs, so that we can fast forward to step 3, which is this pr, and then on next deployment, when the new migration is run, the columns will be dropped, did I miss anything? |
In a standard release process, where we want to ensure zero down time, we will need to be able to perform blue-green deployment, where we keep the old writer running while starting the new writer. So there will be a period of time where both old writer and new writer are running. In this case, when the new writer removes a column, the old writer will fail because it would still attempt to write to the dropped column (even if they are null). Same issue applies to readers. So in the future the proper way would be that we need to update the Rust type first before we drop the column. However, if we want to speed up the process, I think we could ignore the proper rollout for now and always first shutdown the old indexer instances and then star the new one, which would avoid this problem, but with a few mins down time. |
I think this is fine for now -- my main interest in following the backwards compatibility process is to test it out (and discover interesting edge cases like the impact of blue-green deployment on how quickly we can move) and less about actually maintaining backwards compatibility or reducing down time at the moment. |
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.
Change looks good as well, thanks for the clean-up @gegaowp !
876bc4e
to
61260d5
Compare
61260d5
to
d969ce9
Compare
26cc857
to
ac149e6
Compare
ac149e6
to
af2f7a7
Compare
7928f9b
to
27fb7a8
Compare
27fb7a8
to
50feadf
Compare
50feadf
to
ff55250
Compare
ff55250
to
16a853b
Compare
16a853b
to
97a5942
Compare
97a5942
to
4ff1fc4
Compare
4ff1fc4
to
00415c9
Compare
00415c9
to
75c5b17
Compare
## Description df_ columns except df_kind references have been removed from both indexer reader and graphql, this pr removes them from the ingestion path. to make it happen, some refactoring was necessary, previously `StoredObject` was the `From` source Stored* of `objects_history` and `objects_snapshot`, this pr changes the source to `IndexedObject`, which is more intuitive as `StoredObject` is supposed to be coupled with `objects` table while `IndexedObject` is table agnostic. ## Test plan ci and local run --- ## Release notes Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required. For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates. - [ ] Protocol: - [ ] Nodes (Validators and Full nodes): - [ ] Indexer: - [ ] JSON-RPC: - [ ] GraphQL: - [ ] CLI: - [ ] Rust SDK: - [ ] REST API: --------- Co-authored-by: Will Yang <willyang@mystenlabs.com>
Description
df_ columns except df_kind references have been removed from both indexer reader and graphql, this pr removes them from the ingestion path.
to make it happen, some refactoring was necessary, previously
StoredObject
was theFrom
source Stored* ofobjects_history
andobjects_snapshot
, this pr changes the source toIndexedObject
, which is more intuitive asStoredObject
is supposed to be coupled withobjects
table whileIndexedObject
is table agnostic.Test plan
ci and local run
Release notes
Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required.
For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates.