Repository navigation
Resubmit 'Skip back up of refreshable materialized view targets' #93076 - #93658
Conversation
|
Workflow [PR], commit [07d363e] Summary: ❌
|
68febe5 to
3f5eaa7
Compare
| res_table_info.create_table_query = create_table_query; | ||
| res_table_info.metadata_path_in_backup = metadata_path_in_backup; | ||
| res_table_info.data_path_in_backup = data_path_in_backup; | ||
| res_table_info.should_backup_data = shouldBackupTableData(qualified_name, storage); |
There was a problem hiding this comment.
should_backup_data means almost the opposite of backup_settings.structure_only, so I suggest checking backup_settings.structure_only in shouldBackupTableData() and then checking only res_table_info.should_backup_data where it's possible.
| return mv && mv->isRefreshable() && !append && mv->getTargetTable() == target; | ||
| }; | ||
| if (!dependents.empty() | ||
| && std::all_of( |
There was a problem hiding this comment.
I've been debating myself about this. I can't think of an example where a mixture of RVM w/ replace strategy and regular MV or RVM w/ append strategy is used. std::any_of is also fine, I think.
introduce isTargetForReplaceRefreshableMaterializedView to backup utils document
7c4c865 to
e0bc031
Compare
|
@jkartseva Please take a look at #93553 |
|
I replied in the issue. |
| /// replace the table on each refresh (without APPEND), as they contain | ||
| /// transient data that can be recomputed. Targets with APPEND or regular | ||
| /// materialized views are always backed up because they may store history. | ||
| bool backup_data_from_refreshable_materialized_view_targets = false; |
There was a problem hiding this comment.
Are there any cases where it makes sense to set it to true?
There was a problem hiding this comment.
I can't think of any, I made this setting for compatibility in case customers complain that they need an additional REFRESH and WAIT view after the backup is completed.
|
flaky test with increased constants has failed because it hit the 300m timeout https://github.com/ClickHouse/ClickHouse/actions/runs/20968911928/job/60269395190?pr=93658 |
This reverts commit 77fff80.
6f9b4b2
…ialized view targets' #93076
…ialized view targets' #93076
…ialized view targets' #93076
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Introduced
backup_data_from_refreshable_materialized_view_targetsbackup setting to control whether to back up data of refreshable materialized views. Targets of RMVs with APPEND refresh strategy are always backed up.Documentation entry for user-facing changes
Version info
26.1.1.49425.12.4.23,25.11.7.38,25.10.5.37