[Enhancement] Introduce SCHEDULE keyword as ASYNC synonym for MV refresh#72329
Conversation
Per the IMV V1 PRD, the trigger framework keyword for scheduled refresh is renamed to SCHEDULE. ASYNC is preserved as a parser-level synonym so existing scripts continue to work; SHOW CREATE displays the new SCHEDULE keyword. Production: - Grammar: refreshSchemeDesc now accepts (ASYNC | SCHEDULE) as equivalent tokens for the scheduled refresh form. Both keywords are already declared in the lexer and listed as non-reserved. - AstBuilder.visitRefreshSchemeDesc: branch on ASYNC || SCHEDULE; both produce the same AsyncRefreshSchemeDesc. - MaterializedView.getMaterializedViewDdlStmt: emit "SCHEDULE" in place of "ASYNC" for MaterializedViewRefreshType.ASYNC. The persisted enum is unchanged; only the user-facing display is updated. Tests: - Add a synonym test (testAsyncIsSynonymForScheduleAndShowCreatePrefers Schedule) covering both keywords in CREATE and asserting SHOW CREATE output uses SCHEDULE. - Update the parameterized refreshArgumentsList in ShowCreateMaterializedViewStmtTest from REFRESH ASYNC to REFRESH SCHEDULE so the SHOW CREATE round-trip assertion matches the new display. - Update testAlterRefreshScheme to translate ASYNC→SCHEDULE when comparing the SHOW CREATE output of an ALTER REFRESH ASYNC ... statement. - Update SQL integration R files where SHOW CREATE output appears (test_enable_mv, test_random_distribution) to expect SCHEDULE. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> Signed-off-by: Youngwb <yangwenbo_mailbox@163.com>
|
@codex review |
|
Codex Review: Didn't find any major issues. Keep it up! ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
🌎 Translation Required?✅ All translation files are up to date.
|
[Java-Extensions Incremental Coverage Report]✅ pass : 0 / 0 (0%) |
[FE Incremental Coverage Report]✅ pass : 6 / 6 (100.00%) file detail
|
[BE Incremental Coverage Report]✅ pass : 0 / 0 (0%) |
|
@Mergifyio backport branch-4.1 |
✅ Backports have been createdDetails
Cherry-pick of 112df75 has failed: To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally |
…esh (StarRocks#72329) Signed-off-by: Youngwb <yangwenbo_mailbox@163.com> Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…esh (StarRocks#72329) Signed-off-by: Youngwb <yangwenbo_mailbox@163.com> Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Why I'm doing:
What I'm doing:
the trigger framework keyword for scheduled refresh is renamed to SCHEDULE. ASYNC is preserved as a parser-level synonym so existing scripts continue to work; SHOW CREATE displays the new SCHEDULE keyword.
Production:
Tests:
Fixes #issue
What type of PR is this:
Does this PR entail a change in behavior?
If yes, please specify the type of change:
Checklist:
Bugfix cherry-pick branch check: