Commit Graph

112741 Commits

Author SHA1 Message Date
MikhailBurdukov
2cd3512a5d
ClickHouse startup error when loading a distributed table that depends on a dictionary (#48419)
* Test for start failure.

* Handling the dictionary as shard key.

* Added integration test and fixed style

* Revert extra test

* Fix style

* Fix style

* Refactoring

* Fix build

* style fix
2023-04-12 15:06:02 +03:00
Robert Schulze
cf05bf663c
Add test for old bug #7826 2023-04-12 12:03:07 +00:00
Nikolai Kochetov
f66e9c5a26
Merge pull request #48427 from ClickHouse/update_sort_desc_follow_up
Update sort desc: more efficient original node search in ActionsDAG
2023-04-12 13:59:37 +02:00
Igor Nikonov
03accb24bd Fix shellcheck: messed up filename 2023-04-12 11:42:03 +00:00
Nikolay Degterinsky
ff20acf076
Merge pull request #48445 from evillique/array-functions-date-datetime-support
Add support for Date/DateTime datatypes to arrayMin/Max, arrayDifference functions
2023-04-12 13:27:17 +02:00
Robert Schulze
6b441b40dd
Update MergeTree syntax for optional index granularity argument
This is follow up to #45451.
2023-04-12 11:16:55 +00:00
FriendLey
63928c6df0
Merge branch 'master' into test_soundex 2023-04-12 19:06:05 +08:00
alesapin
8ebad126e2
Merge pull request #48516 from MikhailBurdukov/mburdukov_multi_settings
"changed" flag in system.settings is calculated incorrectly for settings with multiple values
2023-04-12 12:54:50 +02:00
alesapin
f4573d64df Fix test 2023-04-12 12:52:40 +02:00
Kruglov Pavel
aa57cdb5f3
Merge pull request #48670 from azat/fix-lock-order-inversion-for-remote
Remove lock for duplicated parts UUIDs (allow_experimental_query_deduplication=1)
2023-04-12 12:42:12 +02:00
Nikolai Kochetov
bc4755952b
Merge pull request #48405 from ClickHouse/analyzer-additional-filters
Support additional filters in new planner
2023-04-12 12:38:57 +02:00
alesapin
55c3f1ee29
Merge pull request #48666 from ClickHouse/remove_strange_code_from_mutation_task
Remove strange code from MutateTask
2023-04-12 12:38:43 +02:00
Igor Nikonov
4f2f5f9cad Merge remote-tracking branch 'origin/master' into igor/analyzer-test-fixes 2023-04-12 10:10:15 +00:00
Igor Nikonov
8bac3d2e5d Fix shellcheck 2023-04-12 10:09:27 +00:00
Igor Nikonov
943f9f541b Call IProcessor::onCancel() once 2023-04-12 10:04:31 +00:00
Azat Khuzhin
5277c802f7 Fix table dependencies in case of failed RENAME TABLE
CI found this [1]

    [ 382620 ] {} <Error> Application: Caught exception while loading metadata: Code: 60. DB::Exception: Table test_25.join doesn\'t exist: While processing _CAST(joinGet(test_25.join, \'m\', CAST(\'42\', \'int\')) AS m_tmp_alter1351896088559986425, \'Int32\') AS m: default expression and column type are incomp
    [ 382620 ] {} <Error> Application: Code: 60. DB::Exception: Table test_25.join doesn\'t exist: While processing _CAST(joinGet(test_25.join, \'m\', CAST(\'42\', \'int\')) AS m_tmp_alter1351896088559986425, \'Int32\') AS m: default expression and column type are incompatible.: Cannot attach table `test_25`.`t

  [1]: https://s3.amazonaws.com/clickhouse-test-reports/48670/d7f865037266ed87538cf4df7ec7e8165681871b/stress_test__asan_.html

The problem here is that after failed RENAME dependencies got lost:

    [4e937f39d866] 2023.04.12 00:51:06.833624 [ 13419 ] {61429225-64cb-4fce-b60d-01e0dac6e52c} <Error> executeQuery: Code: 241. DB::Exception: Memory limit (total) exceeded: would use 34.65 GiB (attempt to allocate chunk of 2097419 bytes), maximum: 34.29 GiB. OvercommitTracker decision: Memory overcommit has freed not enough memory. (MEMORY_LIMIT_EXCEEDED) (version 23.4.1.1) (from [::1]:45710) (comment: 01160_table_dependencies.sh) (in query: create database test_25_1), Stack trace (when copying this message, always include the lines below):
    [4e937f39d866] 2023.04.12 00:51:07.351914 [ 5151 ] {66d8bdd4-668e-4239-a8af-6b8f17bb5222} <Error> executeQuery: Code: 81. DB::Exception: Database test_25_1 doesn't exist. (UNKNOWN_DATABASE) (version 23.4.1.1) (from [::1]:45762) (comment: 01160_table_dependencies.sh) (in query: rename table t to test_25_1.t), Stack trace (when copying this message, always include the lines below):

And from the test output:

    OK
    OK
    OK
    OK
    a       []      []      []
    data_02344      []      []      []
    date_table      []      []      []
    dict1   []      ['dict_src']    ['join']
    dict2   []      ['join']        []
    dict_src        []      []      ['dict1']
    dist_02346      []      []      []
    join    []      ['dict1']       ['dict2','s']
                                    ^^^^^^^^^^^^^ no "t"

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-04-12 11:11:05 +02:00
Robert Schulze
f619208b86
Merge pull request #48673 from ClickHouse/rs/roundAge
Fix roundAge()
2023-04-12 10:32:04 +02:00
Robert Schulze
53d0f76762
Fix fasttest 2023-04-12 08:31:13 +00:00
Sema Checherinda
cc17014516 show result of minio listings for test test_attach_detach_partition 2023-04-12 10:09:25 +02:00
Robert Schulze
9c653197a4
Update roundAge() docs 2023-04-12 08:05:46 +00:00
Robert Schulze
58d98fa21f
Revert "Fix roundAge()"
This reverts commit 38e89b892a.
2023-04-12 07:57:00 +00:00
SmitaRKulkarni
dd64eaed66
Merge pull request #47985 from Algunenano/zk_retry_timeout
Do not continue retrying to connect to ZK if the query is killed or over limits
2023-04-12 08:49:47 +02:00
flynn
ea9187511e Make Schema inference works for CREATE AS SELECT 2023-04-12 04:21:03 +00:00
taiyang-li
e29cce4db9 support map node for json extract 2023-04-12 10:18:07 +08:00
Dmitry Novik
235ad55bad
Merge branch 'master' into analyzer-additional-filters 2023-04-12 01:13:38 +02:00
Igor Nikonov
ace8dc549a Fix 02496_remove_redundant_sorting for analyzer 2023-04-11 21:40:37 +00:00
Igor Nikonov
524e28b02c Remove headers from EXPLAIN in 02496_remove_redundant_sorting 2023-04-11 21:30:16 +00:00
Igor Nikonov
9b5decc2ea Analyzer: fix 02500_remove_redundant_distinct test 2023-04-11 21:19:40 +00:00
Robert Schulze
38e89b892a
Fix roundAge() 2023-04-11 20:31:35 +00:00
alesapin
f91309d83d Fix drop in compact parts 2023-04-11 21:21:42 +02:00
Azat Khuzhin
1d9a785b9b Add missing includes (due to removing ThreadPool.h from PipelineExecutor.h)
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-04-11 20:45:46 +02:00
Robert Schulze
3c6aa46d4a
Update docs 2023-04-11 18:31:00 +00:00
Robert Schulze
05606a8835
Clean up GCC warning pragmas 2023-04-11 18:21:08 +00:00
Azat Khuzhin
d7f8650372 Remove lock for duplicated parts UUIDs (allow_experimental_query_deduplication=1)
It looks redundant, since sendQuery() cannot be executed in parallel
with processPacket() (hence RemoteQueryExecutor::setPartUUIDs())

This likely will fix the lock-order-inversion in RemoteQueryExecutor,
since I think it is false-positive.

Fixes: #48534
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-04-11 20:19:32 +02:00
alesapin
a72ee0b85e Merge remote-tracking branch 'origin/master' into revert-46909-revert-45911-mutations_rename_hang 2023-04-11 20:14:43 +02:00
Robert Schulze
dcfd843b2d
Merge pull request #48489 from ClickHouse/rs/date_time-alias
Register datediff and trim aliases in system.functions
2023-04-11 19:53:44 +02:00
alesapin
165edd332e Remove strange code from MutateTask 2023-04-11 18:31:53 +02:00
Robert Schulze
a1ff8a0679
Remove the obvious 2023-04-11 16:27:32 +00:00
Robert Schulze
609b892879
Fold several Clang-related configurations under one if 2023-04-11 16:27:32 +00:00
Robert Schulze
1477887259
Initial removal of logic under COMPILER_GCC 2023-04-11 16:27:32 +00:00
Dmitry Novik
52f3406bbb Fix CurrentMetrics::MergesMutationsMemoryTracking value 2023-04-11 16:10:59 +00:00
Sergei Trifonov
7c309a0134
Merge branch 'master' into mburdukov_multi_settings 2023-04-11 17:53:43 +02:00
robot-ch-test-poll1
17aecb797c
Merge pull request #48642 from ClickHouse/Avogar-patch-3
Fix flaky test test_drop_replica_and_achieve_quorum
2023-04-11 17:45:53 +02:00
Dmitry Novik
06e6794fc0 Merge remote-tracking branch 'origin/master' into background-memory-tracker 2023-04-11 15:29:35 +00:00
kssenii
e32c98e412 Close spark session 2023-04-11 17:25:32 +02:00
Alexander Tokmakov
1982e2e040
Merge pull request #48662 from hanfei1991/hanfei/refine-expmsg1
fix 02504_regexp_dictionary_table_source
2023-04-11 18:20:10 +03:00
Anton Popov
09c66c3879 fix async inserts with empty data 2023-04-11 15:13:46 +00:00
Han Fei
bf28be8837 fix 02504_regexp_dictionary_table_source 2023-04-11 17:07:44 +02:00
Alexander Tokmakov
d85ede23a3
Merge pull request #48610 from azat/tests/fix-log-level
Fix flakiness of test_store_cleanup in case of image rebuild
2023-04-11 17:39:39 +03:00
Mikhail f. Shiryaev
89e4509e68
Merge branch 'master' into fix-memory-compressed-tables 2023-04-11 16:38:51 +02:00