Commit Graph

51 Commits

Author SHA1 Message Date
Vitaly Baranov
794eeb5d51 Split "total_size" to "uncompressed_size" and "compressed_size". 2022-07-27 10:36:56 +02:00
Vitaly Baranov
a79fc17235 Add test for system.backups 2022-07-27 09:04:10 +02:00
Vitaly Baranov
51a2bf33e8 Rename backup statuses to CREATING_BACKUP, BACKUP_CREATED, BACKUP_FAILED, RESTORING, RESTORED, RESTORE_FAILED. 2022-07-27 09:04:10 +02:00
Vitaly Baranov
fc16a15ecf Rename column "uuid" -> "id" in system.backups and allow user to set it in a query. 2022-07-27 09:04:10 +02:00
Vitaly Baranov
131019ba49 Rename column "backup_name" -> "name" in system.backups. 2022-07-27 09:04:10 +02:00
Vitaly Baranov
6174fe1d72 Fix tests. 2022-07-22 18:33:46 +02:00
Vitaly Baranov
2f47be5da7 Check that the destination for a backup is not in use. 2022-07-15 13:34:58 +02:00
Vitaly Baranov
43d35eec1b Write unfinished mutations to backup. 2022-07-05 14:51:09 +02:00
Vitaly Baranov
e367d96964 Fix style. 2022-06-30 15:10:33 +02:00
Vitaly Baranov
031ca28fdc Add test for partition clause. More checks for data compatibility on restore. 2022-06-30 08:37:18 +02:00
Vitaly Baranov
11b51d2878 Implement storing UDF in backups. 2022-06-30 08:37:17 +02:00
Vitaly Baranov
64b51a3772 Improve gathering metadata for backup. 2022-06-30 08:37:17 +02:00
Vitaly Baranov
47ac47350b Store projections in backups. 2022-06-30 08:37:17 +02:00
Vitaly Baranov
5ae8fce1ef Attach threads to thread groups better. 2022-06-22 18:51:41 +02:00
Vitaly Baranov
b0d19328b8 Add test for ReplicatedAccessStorage. 2022-06-19 14:14:41 +02:00
Vitaly Baranov
9f197defda Add support for setting 'allow_backup' to skip access entities from putting to backup. 2022-06-19 12:49:50 +02:00
Vitaly Baranov
01aaaf7395 More accurate access checking for RESTORE. 2022-06-19 11:26:41 +02:00
Vitaly Baranov
de9a07d18d Fix RESTORE ALL for tables without database in backup. 2022-06-18 14:07:01 +02:00
Vitaly Baranov
36475c5b98 Fix handling empty files in backups. 2022-06-18 12:28:32 +02:00
Vitaly Baranov
a0c558a17e Implement backup/restore for ACL system tables (system.users, system.roles, etc.) 2022-06-17 18:14:31 +02:00
Vitaly Baranov
c2c35fad82 Refactoring of the code getting create table queries for backup. 2022-06-15 20:32:35 +02:00
Vitaly Baranov
1198e86295 Fix storing temporary tables and skipping system tables while making a backup. 2022-06-15 20:32:34 +02:00
Vitaly Baranov
b2323991d6 BACKUP DATABASE now stores inner tables of matviews only if the corresponding matviews are stored. 2022-06-15 20:32:34 +02:00
Vitaly Baranov
6877b8f864 Fix renaming visitor. 2022-06-15 20:32:34 +02:00
Vitaly Baranov
d78a2cda72 Restore tables regarding their dependencies. 2022-06-15 20:32:34 +02:00
Vitaly Baranov
ce1836f0d2 Lock tables for share before backup and restore. 2022-06-15 20:28:43 +02:00
Vitaly Baranov
131382e025 Fix async tests. 2022-06-15 20:28:42 +02:00
Vitaly Baranov
c1baad0763 Fix style. 2022-05-15 14:09:42 +02:00
Vitaly Baranov
23322b0bf6 Add async tests. 2022-05-12 19:42:05 +02:00
Vitaly Baranov
1b2eb4fe27 Use more clear syntax for BACKUP/RESTORE. 2022-05-08 10:37:02 +02:00
Vitaly Baranov
202dd864ed Fix compilation. 2022-05-03 18:34:29 +02:00
Vitaly Baranov
828f45f078 Add new restore setting 'allow_non_empty_tables'. 2022-05-03 16:18:45 +02:00
Vitaly Baranov
a8e924caf6 Make BACKUP & RESTORE synchronous by default. 2022-04-26 18:45:39 +02:00
Vitaly Baranov
78bcb96098 Rename backup & restore setting 'async' -> 'sync', and make backup & restore async by default. 2022-04-26 09:51:19 +02:00
Vitaly Baranov
4de4fff590 Fix tests. 2022-04-25 16:34:34 +02:00
Vitaly Baranov
68a020ecea Implement BACKUP/RESTORE ON CLUSTER. 2022-04-25 16:34:33 +02:00
Vitaly Baranov
ec5b89a6ac Revert backup version 2. Add parameter data_file_path to handle duplicate files more easily without introducing a new backup format. 2022-04-25 16:34:33 +02:00
Vitaly Baranov
f14613f433 Implemented backup version 2: now files in backups are named by their checksums.
It will allow to store duplicate files only one time.
2022-04-25 16:34:33 +02:00
Vitaly Baranov
d20b3d78c5 Rename some restore settings. 2022-04-25 16:34:17 +02:00
Mikhail f. Shiryaev
e6f5a3f98b
Apply black formatter to all *.py files in the repo 2022-03-22 17:39:58 +01:00
Vitaly Baranov
51fc556fcd Implement BACKUP and RESTORE for MatViews. 2022-03-21 11:45:21 +01:00
Vitaly Baranov
18173d71fb A corresponding file in base backup can be searched by checksum too, not only by name. 2022-03-20 20:02:15 +01:00
Vitaly Baranov
5f195d6ead Implement writing backups as zip archive. 2022-03-20 20:02:15 +01:00
Vitaly Baranov
e72a343994 Implement BACKUP & RESTORE for the Memory table engine. 2022-03-20 20:02:15 +01:00
Vitaly Baranov
fd1d24f624 Add settings "throw_if_database_exists" and "throw_if_table_exists". 2022-03-20 20:02:15 +01:00
Vitaly Baranov
71359433dd Add parameters "backups.allowed_path" and "backups.allowed_disk" to config. 2021-11-10 11:03:09 +03:00
Vitaly Baranov
508fb6f54f Use external dirs in the integration test to make test not flaky. 2021-11-10 11:03:09 +03:00
Vitaly Baranov
606e94f4cc Fix backup of database. 2021-11-10 11:03:09 +03:00
Vitaly Baranov
cf77c0b3fc New syntax for BACKUP/RESTORE: set backup engine explicitly. 2021-11-09 23:16:40 +03:00
Vitaly Baranov
a1f29d31ea Support BACKUP & RESTORE for log family. 2021-11-01 12:07:17 +03:00