-
Notifications
You must be signed in to change notification settings - Fork 591
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: support deferred mode for alter parallelism #14826
Conversation
Signed-off-by: Shanicky Chen <[email protected]>
Could you please elaborate more on the motivation? |
4821634
to
8575cc9
Compare
Normally, an ALTER statement requires the scaling to succeed before updating the parallelism of the streaming job. However, in some cases, this might not be suitable. For instance, if there's a desire to forcefully change a custom job to automatic, or in emergency situations, such as when the current cluster's parallelism is insufficient for fixed requirements, you might need to forcefully reduce the degree of parallelism. 'deferred' is a parameter thought up by AI, signifying a delayed scaling. |
8575cc9
to
1886acf
Compare
1886acf
to
c17766e
Compare
.as_ref() | ||
.unwrap() | ||
.post_apply_reschedule(&HashMap::new(), &table_parallelism_assignment) | ||
.await?; |
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.
I think it is acceptable to keep such a quick path to modify the streaming job parallelism, but it is better not to have any public documents. It should only be used in urgent situations when the user cluster load is too high and the response time is not timely. Because this can easily cause inconsistencies, after supporting trigger recovery manually we'd better call it here rather than rebooting the meta.
Signed-off-by: Shanicky Chen <[email protected]>
I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.
What's changed and what's your intention?
When using the DEFERRED parameter with commands like ALTER TABLE, it only modifies the parallelism field in the meta information of the streaming job and doesn't perform an actual scaling. The modification is left to be handled by the subsequent auto scale loop.
Checklist
./risedev check
(or alias,./risedev c
)