Commit Graph

26366 Commits

Author SHA1 Message Date
Alexey Milovidov
6322d064b8
Merge pull request #37384 from Avogar/short-circuit-process
Try to improve short circuit functions processing
2022-05-21 23:43:56 +03:00
Alexey Milovidov
d1678c9662
Update ExpressionActions.cpp 2022-05-21 23:43:26 +03:00
Yakov Olkhovskiy
ce1df15e1c
Merge pull request #37377 from ClickHouse/sha256_hash-with-salt
Allow SALT in CREATE USER user1 IDENTIFIED WITH sha256_hash
2022-05-21 14:36:22 -04:00
Maksim Kita
0d69f35b6a Fixed style check 2022-05-21 14:54:45 +02:00
Yakov Olkhovskiy
6e3f741a25 allow SALT only for SHA256_HASH 2022-05-20 17:21:04 -04:00
Maksim Kita
42439aeb3c Improve performance of number comparison functions 2022-05-20 22:42:48 +02:00
Alexey Milovidov
c77b078c2c
Merge pull request #37367 from ClickHouse/grouping-sets-with-rollup-cube
Disable WITH ROLLUP/CUBE for GROUPING SETS
2022-05-20 22:34:56 +03:00
avogar
22b072bc7f Make better 2022-05-20 13:04:43 +00:00
avogar
3884819bd1 Fix 2022-05-20 12:48:58 +00:00
Yakov Olkhovskiy
1fdcb9b727 test added 2022-05-20 08:41:27 -04:00
Yakov Olkhovskiy
962b72ebf0 unused argument removed 2022-05-20 08:10:29 -04:00
avogar
5d19150906 Try to improve short circuit functions processing 2022-05-20 10:47:28 +00:00
Kruglov Pavel
4dd447b232
Merge pull request #37332 from Avogar/schema-inference-with-globs
Apply input_format_max_rows_to_read_for_schema_inference for all files in globs in total
2022-05-20 12:42:32 +02:00
alesapin
e8ea0d4381
Merge pull request #37036 from ClickHouse/keeper-preprocess-operations
Add support for preprocessing ZooKeeper operations in `clickhouse-keeper`
2022-05-20 11:34:56 +02:00
Kseniia Sumarokova
ee295038fa
Merge pull request #37214 from Vxider/wv-engine
Change ENGINE behavior in WindowView
2022-05-20 11:14:19 +02:00
Kseniia Sumarokova
5b179bda3d
Merge pull request #37338 from xiedeyantu/optimize-cache
optimize file segment PARTIALLY_DOWNLOADED get read buffer
2022-05-20 11:11:56 +02:00
Robert Schulze
b475fbc9a7
Merge pull request #37300 from ClickHouse/cmake-cleanup-pt3
Various cmake cleanups
2022-05-20 10:02:36 +02:00
Sergei Trifonov
2450ab9079
Merge pull request #36686 from azat/disk-least-used
Implement least_used load balancing algorithm for disks inside volume
2022-05-20 09:16:07 +02:00
Yakov Olkhovskiy
a8b2f12111 allow SALT in sha256_hash 2022-05-19 21:55:41 -04:00
Alexander Tokmakov
c2762fd8b3
Merge pull request #37319 from lingo-xp/bug-fix
[bug-fix] root_dir is not set in copyThroughBuffers
2022-05-19 22:17:10 +03:00
Dmitry Novik
86d48e1c99 Disable WITH ROLLUP/CUBE for GROUPING SETS 2022-05-19 14:10:04 +00:00
Alexander Tokmakov
a53cfa9fca
Merge pull request #37355 from ClickHouse/revert-37266-fix-mutations-with-object
Revert "Fix mutations in tables with columns of type `Object`"
2022-05-19 16:27:22 +03:00
Vxider
4290cbc818 update create windowview syntax 2022-05-19 13:05:05 +00:00
Vxider
f6cc73235b Merged with master 2022-05-19 13:03:45 +00:00
Kseniia Sumarokova
d4ad138a04
Merge pull request #37103 from bigo-sg/hive_partition_key_read
optimization for reading hive file  when all columns to read are partition keys
2022-05-19 14:24:00 +02:00
xiedeyantu
6338368a1c optimize file segment getCacheReadBuffer 2022-05-19 20:14:52 +08:00
Kseniia Sumarokova
b0c7cf910a
Merge pull request #37224 from Vxider/wv-fix-dependency
Fix addDependency in WindowView
2022-05-19 13:51:11 +02:00
Kseniia Sumarokova
24d0899cb7
Merge pull request #36945 from Vxider/wv-populate
POPULATE support for WindowView
2022-05-19 13:47:52 +02:00
Kseniia Sumarokova
af2d9154e1
Merge pull request #37279 from bigo-sg/hive_local_cache_multi_disk
Support multi disks for caching hive files
2022-05-19 13:25:03 +02:00
Kseniia Sumarokova
791cc5ced1
Merge pull request #37290 from azat/query-kind-client
Add ability to pass QueryKind via clickhouse-client/local (useful for debugging)
2022-05-19 13:22:42 +02:00
Azat Khuzhin
a350991284 Disks: More accurate free space calculation for least_used
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-05-19 14:10:11 +03:00
Azat Khuzhin
757894b10f Disks: Introduce IReservation::getUnreservedSpace()
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-05-19 14:10:11 +03:00
Azat Khuzhin
1d98913f90 Disks: Reduce number of statfs() calls for least_used disk load balancing policy
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-05-19 14:10:11 +03:00
Azat Khuzhin
ba26b3cf4c Implement lead_used load balancing algorithm for disks inside volume
v2: rebase on top removed raid1
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-05-19 14:10:11 +03:00
Azat Khuzhin
4bc849b9f0 Disks: Remove unused src/Disks/SingleDiskVolume.cpp
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-05-19 14:10:11 +03:00
Azat Khuzhin
9d734bd677 Disks: Remove mentions about RAID1
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-05-19 14:10:11 +03:00
mergify[bot]
426a4d7170
Merge branch 'master' into keeper-preprocess-operations 2022-05-19 10:42:14 +00:00
Alexander Tokmakov
f787dc7097
Revert "Fix mutations in tables with columns of type Object" 2022-05-19 13:24:48 +03:00
Maksim Kita
495e04d2c3
Merge pull request #37242 from jinjunzh/insert_improve_jsp
Improve CompressedWriteBuffer to avoid unnecessary memcpy
2022-05-19 10:59:35 +02:00
Mikhail f. Shiryaev
32769caf04
Merge pull request #37346 from ClickHouse/22.6-prepare
Update version after release
2022-05-19 10:54:53 +02:00
Mikhail f. Shiryaev
d0fe794fe5
Update version to 22.6.1.1 2022-05-19 10:06:09 +02:00
Vitaly Baranov
16c8e93dd0
Merge pull request #36941 from nvartolomei/nv/show-grants-current-roles
Allow a user to inspect grants from granted roles
2022-05-19 09:20:52 +02:00
Yakov Olkhovskiy
cd2ae72aac
Merge pull request #37273 from ClickHouse/client-dns-list
Multiple client connection attempts if hostname resolves to multiple addresses
2022-05-19 01:50:39 -04:00
Azat Khuzhin
29a8a00656 Add ability to pass QueryKind via clickhouse-client/local (useful for debugging)
v2: fix LocalConnection::sendQuery() for Suggest (comes w/o client_info) [1]
    [1]: https://s3.amazonaws.com/clickhouse-test-reports/37290/7c85175963226ff78eec542efafcff4e650aa0f0/stateless_tests__ubsan__actions_.html
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-05-19 07:19:27 +03:00
Azat Khuzhin
54a6aaef62 Log query processing stage in executeQuery()
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-05-19 07:19:26 +03:00
Azat Khuzhin
dea1706d4e
Fix GROUP BY AggregateFunction (#37093)
* Fix GROUP BY AggregateFunction

finalizeChunk() was unconditionally converting AggregateFunction to the
underlying type, however this should be done only if the aggregate was
applied.

So pass names of aggregates as an argument to the finalizeChunk()

Fuzzer report [1]:

    Logical error: 'Bad cast from type DB::ColumnArray to DB::ColumnAggregateFunction'. Received signal 6 Received signal Aborted (6)

For the following query:

    SELECT
        arraySort(groupArrayArray(grp_simple)),
        grp_aggreg,
        arraySort(groupArrayArray(grp_simple)),
        b,
        arraySort(groupArrayArray(grp_simple)) AS grs
    FROM data_02294
    GROUP BY
        a,
        grp_aggreg,
        b
    SETTINGS optimize_aggregation_in_order = 1

  [1]: https://s3.amazonaws.com/clickhouse-test-reports/37050/323ae98202d80fc4b311be1e7308ef2ac39e6063/fuzzer_astfuzzerdebug,actions//fuzzer.log

v2: fix conflicts in src/Interpreters/InterpreterSelectQuery.cpp
v3: Fix header for GROUP BY AggregateFunction WITH TOTALS
v4: Add sanity check into finalizeBlock()
v5: Use typeid_cast<&> to get more sensible error in case of bad cast (as suggested by @nickitat)
v6: Fix positions passed to finalizeChunk()
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>

* Core/ColumnNumbers.h: remove unused <string>

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>

* Optimize finalizeChunk()/finalizeBlock()

v2: s/ByPosition/Mask/ s/by_position/mask/
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-05-18 23:37:43 +02:00
Vitaly Baranov
7c8956ca8d
Merge pull request #36879 from tonickkozlov/tonickkozlov/lazy-marks-loading
Lazy marks loading
2022-05-18 22:56:46 +02:00
Robert Schulze
1d89738c6a
Remove performance workaround for old GCC
GCC support these days is experimental. GCCs main use is to keep the
code portable but I don't think it's used for performance tests. Hence
removing a performance workaround added in the GCC 7 days (we are now
using 11, soon: 12).
2022-05-18 22:44:37 +02:00
avogar
cd6a29897e Apply input_format_max_rows_to_read_for_schema_inference for all files in globs in total 2022-05-18 17:56:36 +00:00
Vitaly Baranov
9ccddc44c6
Merge pull request #35767 from azat/ON_CLUSTER-grant
RFC: Add separate CLUSTER grant
2022-05-18 19:19:54 +02:00