Commit Graph

1258 Commits

Author SHA1 Message Date
Nikita Mikhaylov
2933a28a5d
Add log message and lower the retry timeout in MergeTreeRestartingThread (#42026) 2022-10-04 20:07:11 +02:00
alesapin
425b296928 Revert "Revert "Merge pull request #41832 from ClickHouse/make_copy_instead_of_hardlink""
This reverts commit f50d46fb8c.
2022-10-04 17:40:23 +02:00
alesapin
6f185333ff Fix drop completely dropped table one more time 2022-10-04 17:39:28 +02:00
alesapin
f50d46fb8c Revert "Merge pull request #41832 from ClickHouse/make_copy_instead_of_hardlink"
This reverts commit 0097f15ee7, reversing
changes made to 4e422b8046.
2022-10-04 17:33:01 +02:00
alesapin
2bfae244cc Add comments 2022-10-04 17:30:25 +02:00
alesapin
210882b9c4 Better fix 2022-10-03 23:30:50 +02:00
alesapin
71e1b1df73 add comment 2022-10-03 19:09:24 +02:00
alesapin
3114ddcad2 Fix failure during table drop 2022-10-03 19:06:12 +02:00
alesapin
350ff96628 Fix potential race condition with broken parts 2022-09-30 19:01:06 +02:00
alesapin
0097f15ee7
Merge pull request #41832 from ClickHouse/make_copy_instead_of_hardlink
Use copy for some operations instead of hardlinks
2022-09-29 17:12:08 +02:00
Alexander Tokmakov
4e422b8046
Merge pull request #41741 from ClickHouse/fix_intersecting_parts
Fix intersecting parts
2022-09-29 18:00:22 +03:00
alesapin
905d4585ac
Merge branch 'master' into make_copy_instead_of_hardlink 2022-09-28 16:47:45 +02:00
alesapin
9e77d520d4 Merge branch 'master' into make_copy_instead_of_hardlink 2022-09-28 12:10:00 +02:00
alesapin
57614b6869 Remove two redundant lines 2022-09-27 23:16:16 +02:00
alesapin
695133cc5b Better mutations 2022-09-27 15:23:02 +02:00
Alexander Tokmakov
49983dafeb fix 2022-09-26 17:13:10 +02:00
alesapin
e20d3803c4 Better fix 2022-09-26 15:40:25 +02:00
alesapin
2384761063 Fix drop of completely dropped table 2022-09-26 15:38:10 +02:00
Nikita Mikhaylov
dbcba1490c
Try to make MergeTreeRestartingThread more reactive in case of expired sessions (#41092) 2022-09-23 14:40:04 +02:00
alesapin
acde29e314 Nasty code 2022-09-20 17:55:06 +02:00
alesapin
cfe398cbbc Fix lost table shared id during server restart 2022-09-20 14:51:16 +02:00
alesapin
06ccdb1ecf Fix nasty bug 2022-09-16 13:49:39 +02:00
Anton Popov
3623807527
Merge pull request #41290 from CurtizJ/dynamic-columns-20
Fix `ALTER ADD COLUMN`  with columns of type `Object`
2022-09-14 14:15:29 +02:00
Vladimir C
00d0b37cd0
Merge pull request #41263 from ClickHouse/vdimir/quorum-log-msg-fix 2022-09-14 10:54:21 +02:00
Anton Popov
ee54451741 fix adding of columns of type Object 2022-09-13 22:43:59 +00:00
vdimir
f2acb53887
Better log message for replicas number in StorageReplicatedMerge 2022-09-13 13:49:51 +00:00
Alexander Tokmakov
4d146b05a9
Merge pull request #38262 from PolyProgrammist/fix-ordinary-system-unfreeze
Fix SYSTEM UNFREEZE for ordinary database
2022-09-13 14:55:11 +03:00
Alexander Tokmakov
da4fbb552d
Merge branch 'master' into fix_parts_removal 2022-09-12 17:49:29 +03:00
Alexander Tokmakov
7f462a8762
Update src/Storages/StorageReplicatedMergeTree.cpp 2022-09-12 13:22:08 +03:00
alesapin
21ab379026 Fix comment 2022-09-11 13:47:04 +02:00
alesapin
ac53830000 Fix hung check 2022-09-11 13:37:39 +02:00
alesapin
86a3719bef
Merge pull request #41128 from ClickHouse/less_errors
Fix bad warnings in part fetches
2022-09-09 16:58:09 +02:00
Alexander Tokmakov
48927ba0ac
Merge branch 'master' into no-hardlinks-while-making-backup-of-mergetree-in-atomic-db 2022-09-09 14:24:44 +03:00
alesapin
23d95e6723 Fix parts removal in case of failures 2022-09-09 13:24:22 +02:00
alesapin
e3fc78aa5f Fix bad warnings in part fetches 2022-09-09 12:14:42 +02:00
Vitaly Baranov
9acc73d811
Update src/Storages/StorageReplicatedMergeTree.cpp
Co-authored-by: Alexander Tokmakov <tavplubix@gmail.com>
2022-09-08 17:51:29 +02:00
alesapin
5e00124f8a More logging for S3 2022-09-08 16:18:21 +02:00
Vitaly Baranov
122009a2bd Use table lock if database is ordinary and zero-copy-replication is enabled. 2022-09-08 13:54:59 +02:00
alesapin
6da37b92e1 Improve logging one time 2022-09-08 13:11:53 +02:00
Vladimir C
90647cb0c5
Merge pull request #39970 from SachinSetiya/majority_quorum
Add majority_insert_quorum setting
2022-09-08 11:31:33 +02:00
vdimir
6234d564d1
Fix ReplicatedMergeTreeSink, add more info to logs 2022-09-07 11:19:28 +00:00
vdimir
000ba8a60d
Use insert_qurum = auto instead of majority_insert_quorum 2022-09-07 11:19:27 +00:00
Sachin
ade4337978
Add majority_insert_quorum setting
majority_insert_quorum is defined as (number_of_replicas/2)+1. Insert
will be successful only if majority of quorum have applied it. If
insert_quorum and majority_insert_quorum both are specified, max of
both will be used.
2022-09-07 11:19:24 +00:00
alesapin
6ded03c000 Disable fetch shortcut for zero copy replication 2022-09-07 00:00:10 +02:00
alesapin
43493389b9 Merge branch 'master' into one_more_logging 2022-09-06 19:40:24 +02:00
alesapin
b778b9f37f Improve logging better 2022-09-06 19:25:58 +02:00
alesapin
6ea7f1e011 Better exception handling for ReadBufferFromS3 2022-09-06 13:59:55 +02:00
ianton-ru
39e1fc7a0f
Merge branch 'master' into fix-ordinary-system-unfreeze 2022-09-05 17:10:59 +03:00
Luck-Chang
1ac8e739c9 fix some typos and clang-tidy warnings 2022-09-05 09:50:24 +08:00
Alexander Tokmakov
b8e3a582f7 do not try to strartup dropped replica 2022-08-25 22:14:39 +02:00
Alexander Tokmakov
eae2667a1c
Merge pull request #40148 from ClickHouse/replicate-tables-readonly
`ReplicatedMergeTree` tables as readonly until attach is finished
2022-08-25 19:39:19 +03:00
Antonio Andelic
f90612f577 Remove shutdown assert 2022-08-25 07:07:54 +00:00
Antonio Andelic
797e21761a Address PR comments 2022-08-24 18:32:03 +00:00
Antonio Andelic
da0d6056f4 Merge branch 'master' into replicate-tables-readonly 2022-08-24 17:29:33 +00:00
alesapin
eeb0a3584e Merge branch 'master' into data_source_description 2022-08-24 15:26:18 +02:00
Alexander Tokmakov
f9f85a0e8b Revert "Parallel distributed insert select from *Cluster table functions (#39107)"
This reverts commit d3cc234986.
2022-08-24 15:17:15 +03:00
alesapin
d8664c3227 Add shortcut for backups 2022-08-19 16:58:30 +02:00
Antonio Andelic
ee3df77fda Simplify logic 2022-08-19 11:12:20 +00:00
Antonio Andelic
5e2c8869a9 Merge branch 'master' into replicate-tables-readonly 2022-08-19 09:41:11 +00:00
Antonio Andelic
3f7d28cc6b Address PR comments 2022-08-19 09:39:59 +00:00
Antonio Andelic
a8f3b62bf6 Use global zookeeper 2022-08-19 08:49:51 +00:00
Antonio Andelic
6f533313e9 Restart everything during attach 2022-08-19 08:17:02 +00:00
alesapin
4398a357c8
Merge pull request #40151 from ClickHouse/fix_cannot_quickly_remove_directory
Fix "Cannot quickly remove directory"
2022-08-17 12:11:18 +02:00
Alexander Tokmakov
caa270b72a
Merge pull request #39933 from ClickHouse/auto_convert_ordinary_to_atomic
Add flag that enables automatic conversion from Ordinary to Atomic
2022-08-17 12:40:49 +03:00
Antonio Andelic
1936ea6377 Fix test issues 2022-08-17 08:28:53 +00:00
Nikita Mikhaylov
a7c3f23dfb
Merge branch 'master' into auto_convert_ordinary_to_atomic 2022-08-17 00:38:25 +02:00
Alexander Tokmakov
832d7c6e7c Merge branch 'master' into replicated_database_improvements 2022-08-16 15:49:13 +02:00
Antonio Andelic
9ac4ca265a Small initialization fixes 2022-08-16 08:19:02 +00:00
Antonio Andelic
2ed42bca7e Merge branch 'master' into replicate-tables-readonly 2022-08-16 08:17:53 +00:00
Nikita Mikhaylov
d3cc234986
Parallel distributed insert select from *Cluster table functions (#39107) 2022-08-15 12:41:17 +02:00
Alexander Tokmakov
46aaf842f8
Merge pull request #40031 from ClickHouse/fix_old_tmp_dirs_cleanup
Fix old temporary directories cleanup
2022-08-12 20:31:20 +03:00
Antonio Andelic
c6b3a897d2 Test replicated table without ZK, small fixes 2022-08-12 11:56:46 +00:00
Alexander Tokmakov
e691888267 fix build 2022-08-12 13:03:57 +02:00
Antonio Andelic
1c0f85ccdb Attach table in background 2022-08-12 09:32:13 +00:00
vdimir
ae1db8386b
Change type of insert_quorum to UInt64WithAuto 2022-08-09 17:14:02 +00:00
Alexander Tokmakov
fe572104aa fix old tmp dirs cleanup 2022-08-09 18:44:51 +02:00
Alexander Tokmakov
2c5da1466d Merge branch 'master' into replicated_database_improvements 2022-08-08 16:08:27 +02:00
Alexander Tokmakov
f2c4cad255 add flag that enables automatic canversion from Ordinary to Atomic 2022-08-05 21:41:25 +02:00
Alexander Gololobov
b57df6d71d
Merge branch 'master' into wait_for_mutation_race 2022-08-05 18:51:39 +02:00
Alexander Gololobov
f5e358ecc5 Make sure that the current replica is the first on the list 2022-08-04 20:26:39 +02:00
Alexander Gololobov
7caf4c210e Update local queue to see current mutation entry 2022-08-04 14:06:19 +02:00
Alexander Tokmakov
6f88065cc1 check metadata consistency 2022-07-29 18:33:16 +02:00
Anton Popov
57e4fb2e30 Merge remote-tracking branch 'upstream/master' into HEAD 2022-07-29 11:42:11 +00:00
Anton Popov
4cf0353892 try to fix Nested 2022-07-27 14:05:16 +00:00
jianmei zhang
c1834d183b ReplicatedMergeTree support lightweight delete 2022-07-26 11:50:09 +08:00
Vadim Volodin
85bf022258 review zookeeper and partition matching 2022-07-21 16:57:28 +03:00
Alexander Tokmakov
a8da5d96fc remove some dead and commented code 2022-07-21 15:05:48 +02:00
Alexander Tokmakov
3e7414b356 add comment 2022-07-19 12:47:20 +02:00
Alexander Tokmakov
d82f378a9d do not enqueue uneeded parts for check 2022-07-18 23:37:07 +02:00
Raúl Marín
9b0c7714e5 Style 2022-07-07 17:15:23 +02:00
Raúl Marín
c3935000a8 Avoid reporting ZK EEXIST errors on checkPartChecksumsAndCommit 2022-07-07 16:10:05 +02:00
Raúl Marín
33ffb71453 Avoid 'Node exists' errors when creating Ephemeral Locks 2022-07-07 16:10:04 +02:00
alesapin
1bd97fa6fa
Merge pull request #38851 from Algunenano/rmarin_read_only_on_drop
Deactivate mutations_finalizing_task during shutdown
2022-07-07 12:55:50 +02:00
Vitaly Baranov
ed27987646
Merge pull request #38861 from vitlibar/backup-improvements-9
Backup Improvements 9
2022-07-07 02:24:47 +02:00
Vitaly Baranov
43d35eec1b Write unfinished mutations to backup. 2022-07-05 14:51:09 +02:00
Raúl Marín
9e17ae365b Deactivate mutations_finalizing_task during shutdown 2022-07-05 14:28:20 +02:00
Raúl Marín
838fd1e41e Fix replication after improper merge process 2022-07-03 15:11:25 +02:00
alesapin
b2db49dbf1
Merge branch 'master' into better_data_part_storage_builder 2022-07-02 15:39:44 +02:00
Vitaly Baranov
cadb496894
Merge pull request #38537 from vitlibar/backup-improvements-8
Backup Improvements 8
2022-07-01 11:20:46 +02:00
alesapin
979565edf0 Merge branch 'master' into better_data_part_storage_builder 2022-06-30 22:54:42 +02:00
alesapin
eb5046ab26 Simplify everything 2022-06-30 22:51:27 +02:00
Vitaly Baranov
e367d96964 Fix style. 2022-06-30 15:10:33 +02:00
Raúl Marín
cbcd740dc1 Adapt some more nodes to avoid issues with pre-22.4 replicas 2022-06-30 15:10:09 +02:00
alesapin
1363b478d4 Merge branch 'fix_disk_tx_write_op' into better_data_part_storage_builder 2022-06-30 14:38:32 +02:00
alesapin
cb90aca2ef Some changes in merge tree 2022-06-30 14:12:45 +02:00
Vitaly Baranov
efbee5e723 Improve gathering metadata for backup - part 7. 2022-06-30 08:37:17 +02:00
Vitaly Baranov
01921ce9a3 Move most code from setTableStructure() to a separate function. 2022-06-30 08:37:17 +02:00
Vitaly Baranov
7689e0c36f Improve gathering metadata for backup - part 6. 2022-06-30 08:37:17 +02:00
Vitaly Baranov
461a31f237 Improve gathering metadata for backup - part 2. 2022-06-30 08:37:17 +02:00
Vitaly Baranov
64b51a3772 Improve gathering metadata for backup. 2022-06-30 08:37:17 +02:00
alesapin
2f03e821bd Fix stupid bug 2022-06-29 15:08:16 +02:00
Alexander Tokmakov
32c6a944ee
Merge pull request #38541 from Algunenano/rmarin_fix_replicated_create_table_compat
Fix table creation to avoid replication issues with pre-22.4 replicas
2022-06-29 14:15:50 +03:00
alesapin
c80a4c27be Merge branch 'master' into better_data_part_storage_builder 2022-06-29 12:33:42 +02:00
Robert Schulze
f692ead6ad
Don't use std::unique_lock unless we have to
Replace where possible by std::lock_guard which is more light-weight.
2022-06-28 19:19:06 +00:00
Raúl Marín
9b4da86e2e Adapt table creation with replication to avoid issues with pre-22.4 replicas 2022-06-28 20:12:07 +02:00
alesapin
a68bf8fff2 Missed changes 2022-06-28 12:59:54 +02:00
alesapin
49add19842 Merge branch 'better_data_part_storage_builder' of github.com:ClickHouse/ClickHouse into better_data_part_storage_builder 2022-06-28 12:02:27 +02:00
alesapin
d88cdcd5c1 AAA 2022-06-27 21:41:29 +02:00
alesapin
83b584b2dd Something 2022-06-26 18:43:28 +02:00
Vadim Volodin
3296ba2532 Fix SYSTEM UNFREEZE for ordinary database 2022-06-24 20:46:16 +03:00
alesapin
2bc4dc4a1d Fix accident change 2022-06-24 18:38:43 +02:00
alesapin
011d58d7a0 Simplify more 2022-06-24 17:19:59 +02:00
alesapin
37310dc9df Simpler 2022-06-24 14:10:15 +02:00
alesapin
36b810b076 Remove unused parameter 2022-06-24 13:42:36 +02:00
alesapin
af1a9d18ab Remove transaction argument 2022-06-24 13:34:00 +02:00
alesapin
9910395823 Simplify method signature 2022-06-24 13:19:29 +02:00
Nikolai Kochetov
cc6fdfe0eb
Merge pull request #36555 from ClickHouse/refactor-something-in-part-volumes
Separate data storage abstraction for MergeTree
2022-06-22 11:13:36 +02:00
Anton Popov
d5d568e235
Merge pull request #37913 from azat/parts-refcnt
Fix refcnt for unused MergeTree parts in SELECT queries
2022-06-21 22:56:26 +02:00
Nikolai Kochetov
dccf90b1ea Cleanup. 2022-06-20 18:18:17 +00:00
Nikolai Kochetov
7452d04e3a Merge branch 'master' into refactor-something-in-part-volumes 2022-06-20 15:31:02 +02:00
alesapin
119ce90e5b Fix strange diff 2022-06-19 18:03:43 +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
21f3bed435 Simplify path calculations in backup. 2022-06-15 20:32:34 +02:00
Vitaly Baranov
592f568f83 Move backup/restore code to storages and databases - part 2. 2022-06-15 20:32:31 +02:00
Vitaly Baranov
724bc4dc57 Move backup/restore code to storages and databases - part 1. 2022-06-15 20:28:43 +02:00
Vitaly Baranov
73b1894a21 Rework collecting replicated parts. 2022-06-15 20:28:42 +02:00
Vitaly Baranov
5cabdbd982 Restore parts of MergeTree in correct order. 2022-06-15 20:28:40 +02:00
Nikolai Kochetov
25b9990737 Fixing build 2022-06-15 16:32:22 +00:00
Nikolai Kochetov
2a9a63ac7b Merge branch 'master' into refactor-something-in-part-volumes 2022-06-15 15:35:26 +02:00
alesapin
af1cd745e1
Merge pull request #37975 from kssenii/clean-up-broken-detached
Clean up broken detached parts after timeout
2022-06-14 20:53:31 +02:00
Antonio Andelic
b9cf6fe367 Merge branch 'master' into pp-system-unfreeze 2022-06-13 14:46:30 +00:00
kssenii
fd6c84b831 Review fixes 2022-06-10 14:23:13 +02:00
kssenii
498f389c21 Merge master 2022-06-10 12:49:10 +02:00
kssenii
7a2676c7ab Clean up broken detached parts with timeout 2022-06-10 12:27:57 +02:00
Kseniia Sumarokova
508676ab4e
Merge pull request #37804 from ClickHouse/metadata_storage
Metadata storage abstraction for Disks
2022-06-10 11:43:28 +02:00
Alexander Tokmakov
7c30d9b5d3
Merge pull request #37839 from ClickHouse/try_fix_37664
Do not count covered unexpected parts on sanity check
2022-06-09 18:22:37 +03:00
Alexander Tokmakov
780f7c87c7
Merge pull request #36113 from ClickHouse/remove-useless-code-2
Remove useless code in ReplicatedMergeTreeRestartingThread
2022-06-09 17:56:28 +03:00
alesapin
378f9246ca Rename one method 2022-06-08 14:57:10 +02:00
alesapin
56a57e649f First try new interface 2022-06-08 14:56:51 +02:00
Vadim Volodin
637d293fbd Add SYSTEM UNFREEZE query 2022-06-08 15:21:14 +03:00