-
Notifications
You must be signed in to change notification settings - Fork 465
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
Feature/graceful reconfig until ready sql #28821
Feature/graceful reconfig until ready sql #28821
Conversation
4639d4c
to
5b7528d
Compare
a91cb8a
to
35e8a48
Compare
35e8a48
to
843d31c
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 modulo a couple small comments
cb5a83c
to
ead5646
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.
So good!
src/sql/src/plan/error.rs
Outdated
@@ -739,6 +740,9 @@ impl fmt::Display for PlanError { | |||
}, | |||
Self::SubsourceResolutionError(e) => write!(f, "{}", e), | |||
Self::Replan(msg) => write!(f, "internal error while replanning, please contact support: {msg}"), | |||
Self::UntilReadyTimeoutRequired => { | |||
write!(f, "TIMEOUT=<duration> option is required for ALTER CLUSTER ... WITH ( WAIT UNTIL READY ( ... ) )") |
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.
write!(f, "TIMEOUT=<duration> option is required for ALTER CLUSTER ... WITH ( WAIT UNTIL READY ( ... ) )") | |
write!(f, "TIMEOUT=<duration> option is required for ALTER CLUSTER ... WITH (WAIT UNTIL READY ( ... ))") |
src/sql/src/plan/statement/ddl.rs
Outdated
@@ -4894,6 +4901,9 @@ pub fn plan_alter_cluster( | |||
&crate::session::vars::ENABLE_GRACEFUL_CLUSTER_RECONFIGURATION, | |||
)?; | |||
} | |||
AlterClusterPlanStrategy::UntilReady { .. } => { | |||
bail_unsupported!("ALTER CLUSTER .. WITH ( WAIT UNTIL READY...) is not yet implemented"); |
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.
bail_unsupported!("ALTER CLUSTER .. WITH ( WAIT UNTIL READY...) is not yet implemented"); | |
bail_unsupported!("ALTER CLUSTER .. WITH (WAIT UNTIL READY...) is not yet implemented"); |
ead5646
to
fff87dd
Compare
fff87dd
to
1594d23
Compare
add ddl for wait until ready, keeps feature disabled/unimplemented.
1594d23
to
ed90d44
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.
New COMMIT
vs ROLLBACK
syntax LGTM.
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.
Thanks, @jubrad! Linking to the SQL Council thread for posterity.
Motivation
Adds SQL parsing for
ALTER CLUSTER ... WITH ( WAIT UNTIL READY=(<options>) )
where options are
TIMEOUT=<duration>
andON TIMEOUT=<COMMIT|ROLLBACK>
https://github.com/MaterializeInc/database-issues/issues/5976
This PR is stacked on the following PRs
This was formerly known as
until caught up
but the language has been changed tountil ready
for both clarity and to allow us to shift the definition of "ready" internally for this feature without needing to add new sql changes.Tips for reviewer
Checklist
$T ⇔ Proto$T
mapping (possibly in a backwards-incompatible way), then it is tagged with aT-proto
label.