Skip to content
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

PHOENIX-4765 Add client and server side config property to enable rol… #406

Closed
wants to merge 1 commit into from

Conversation

twdsilva
Copy link
Contributor

…lback of splittable System Catalog if required

@ChinmaySKulkarni can you please review. This PR adds a config that is used to enable rollback of splittable SYSTEM.CATALOG if required. If the config is true, we continue storing the parent table column metadata while creating a view. We also block any add columns and while creating a view try to lock the parent table to prevent conflicting concurrent changes.

…lback of splittable System Catalog if required
@twdsilva
Copy link
Contributor Author

@karanmehta93 Can you please review?

// this flag denotes that we will continue to write parent table column metadata while creating
// a child view and also block metadata changes that were previously propagated to children
// before 4.15, so that we can rollback the upgrade to 4.15 if required
private boolean allowSystemCatalogRollback;
Copy link
Contributor

@ChinmaySKulkarni ChinmaySKulkarni Nov 26, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@twdsilva don't we need to have a way to figure out if a rollback is currently in progress as well? Once the rollback has already happened and the SYSTEM.CATALOG timestamp is < the min_splittable_SYSCAT timestamp, can we then acquire locks only when the SYSCAT timestamp is >= min_splittable_SYSCAT timestamp AND allowedSystemCatalogRollback is true, instead of always acquiring locks based on just the value of this new flag?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Had a conversation offline with Thomas and the underlying point in my comment above is already being addressed. Thanks @twdsilva.

@ChinmaySKulkarni
Copy link
Contributor

Once flipped back to "false", setting this flag back to "true" may not cleanly rollback since SYSCAT may have split since then. Let's add a comment about that as well as the SYSTEM.CHILD_LINK metadata that we discussed. Otherwise +1. Thanks @twdsilva

@twdsilva twdsilva closed this Nov 27, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants