Commit Graph

9853 Commits

Author SHA1 Message Date
Maksim Kita
d9d206af92 Fixed typo 2021-02-01 12:35:47 +03:00
Maksim Kita
d3f299269f Fixed code review issues 2021-02-01 12:35:47 +03:00
alexey-milovidov
e5b89f24b5 Update ExecutableDictionarySource.cpp 2021-02-01 12:35:47 +03:00
alexey-milovidov
77a8ef24de Update ExecutableDictionarySource.cpp 2021-02-01 12:35:47 +03:00
alexey-milovidov
ecd6e10e22 Update ExecutableDictionarySource.cpp 2021-02-01 12:35:47 +03:00
alexey-milovidov
b83b8c56da Update ExecutableDictionarySource.cpp 2021-02-01 12:35:47 +03:00
Maksim Kita
a0755e439c Fixed typo 2021-02-01 12:35:47 +03:00
Maksim Kita
a9ecb6bf78 Fixed clang-tidy 2021-02-01 12:35:47 +03:00
Maksim Kita
d194294d0b Fixed tests 2021-02-01 12:35:47 +03:00
Maksim Kita
dafb0ef4e9 ExecutableDictionarySource added implicit_key option 2021-02-01 12:35:47 +03:00
tavplubix
4f955be832
fix sync 2021-02-01 12:32:36 +03:00
Stig Bakken
bedc472bb0 Show MaterializeMySQL tables in system.parts 2021-02-01 16:59:10 +08:00
alexey-milovidov
ef72ba7349
Merge pull request #19861 from amosbird/fixcte
Fix crash when pushing down predicates to union distinct subquery
2021-02-01 10:28:41 +03:00
alexey-milovidov
f4df161672
Merge pull request #19863 from ClickHouse/improve-server-latency
Maybe improve server latency
2021-02-01 10:27:44 +03:00
Alexey Milovidov
49979afbc1 Fix bad translation 2021-02-01 10:12:14 +03:00
Alexey Milovidov
57664bffe0 Amend 2021-02-01 10:11:41 +03:00
alesapin
d9598c47b4
Merge pull request #19702 from ClickHouse/fix_rare_bug_after_part_corruption
Fix incorrect virtual_parts after part corruption
2021-02-01 10:09:48 +03:00
Alexey Milovidov
e9a61c4738 More correct 2021-02-01 07:52:18 +03:00
Alexey Milovidov
1c0c3b3aab Merge branch 'master' into intdiv-ubsan 2021-02-01 07:46:40 +03:00
alexey-milovidov
08f713f177
Merge pull request #14822 from vzakaznikov/live_view_periodic_refresh
Adding support for periodically refreshed LIVE VIEW tables
2021-02-01 06:11:30 +03:00
yiguolei
768e461d28 add functional test 2021-02-01 10:40:48 +08:00
alexey-milovidov
cc23a2b399
Update PredicateRewriteVisitor.cpp 2021-02-01 03:44:40 +03:00
alexey-milovidov
a6b0fdd3eb
Merge pull request #19862 from ClickHouse/ubsan-gather-utils
Fix UBSan report in GatherUtils
2021-02-01 03:43:43 +03:00
alexey-milovidov
9407c5baf4
Merge pull request #19868 from amosbird/fixif
Fix argMinMaxIf crash
2021-02-01 03:42:48 +03:00
Alexander Tokmakov
84d3d6e728 fix 'Unmatched parentheses', add test 2021-02-01 02:10:41 +03:00
Maksim Kita
d2b8d9886f Fixed fuzzer crash 2021-01-31 22:25:53 +03:00
Maksim Kita
1aa8d7fdfb BloomFilter index crash fix 2021-01-31 21:49:27 +03:00
Maksim Kita
a4812aa97b Updated tests 2021-01-31 18:32:47 +03:00
alexey-milovidov
342baa4223
Merge pull request #19720 from ClickHouse/unicode-asan
Fix unsufficient args check (trash code) in StringSearcher
2021-01-31 15:43:05 +03:00
alexey-milovidov
b80ad9f9bc
Merge pull request #19859 from ClickHouse/date-time-add-ubsan
Fix UBSan report in DateTimeAddInterval
2021-01-31 14:09:04 +03:00
vdimir
000b51f95a
Merge pull request #19518 from bharatnc/ncb/toIPv6-parses-IPv4
toIPv6 function parses IPv4 addresses
2021-01-31 13:56:45 +03:00
Alexey Milovidov
ddff28e594 Fix UBSan report in intDiv 2021-01-31 13:23:50 +03:00
Alexey Milovidov
11f144f589 Fix deadlock in system.text_log 2021-01-31 13:02:35 +03:00
Alexey Milovidov
37f88a1468 Whitespace 2021-01-31 12:02:54 +03:00
Azat Khuzhin
978f23e343 Fix SIGSEGV due to accessing GRPCServer::currentConnections() before initialization
This PR makes asynchronous metrics available just after start, and this
breaks GRPCServer, since it requires the server be started before
accessing currentConnections().

However it is possible to trigger the same SIGSEGV even without that
patch, with some timeouts during previous server initilizations and
small asynchronous_metrics_update_period_s.

Fix this by creating GRPCServer::Runner in the ctor.

Stacktrace:
    26.842505 [ 7 ] {} <Information> Application: Listening for MySQL compatibility protocol: 0.0.0.0:9004
    26.842562 [ 7 ] {} <Information> Application: Listening for gRPC protocol: 0.0.0.0:9100
    26.842600 [ 7 ] {} <Debug> AsynchronousMetrics: MemoryTracking: was 350.72 KiB, peak 5.25 MiB, will set to 232.63 MiB (RSS), difference: 232.29 MiB
    26.842834 [ 8 ] {} <Trace> BaseDaemon: Received signal 11
    26.843014 [ 39 ] {} <Fatal> BaseDaemon: ########################################
    26.843055 [ 39 ] {} <Fatal> BaseDaemon: (version 21.2.1.5858, build id: B27D5550AC34F9091BC4437D8021B752EDB34FBB) (from thread 7) (no query) Received signal Segmentation fault (11)
    26.843085 [ 39 ] {} <Fatal> BaseDaemon: Address: 0x78 Access: read. Address not mapped to object.
    26.843104 [ 39 ] {} <Fatal> BaseDaemon: Stack trace: 0x7fe8c4e6afc4 0x13683cf1 0xf52efe5 0xe7c9137 0x85596e1 0x8553635 0x11b7a313 0x8545ebc 0x8544b25 0x84e1cbe 0x7fe8c4c940b3 0x84ac22e
    26.843136 [ 39 ] {} <Fatal> BaseDaemon: 2. pthread_mutex_lock @ 0xbfc4 in /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
    26.843162 [ 39 ] {} <Fatal> BaseDaemon: 3. std::__1::mutex::lock() @ 0x13683cf1 in ?
    26.843188 [ 39 ] {} <Fatal> BaseDaemon: 4. DB::GRPCServer::currentConnections() const @ 0xf52efe5 in /usr/bin/clickhouse
    26.843204 [ 39 ] {} <Fatal> BaseDaemon: 5. DB::AsynchronousMetrics::update() @ 0xe7c9137 in /usr/bin/clickhouse
    26.843228 [ 39 ] {} <Fatal> BaseDaemon: 6. DB::AsynchronousMetrics::start() @ 0x85596e1 in /usr/bin/clickhouse
    26.843248 [ 39 ] {} <Fatal> BaseDaemon: 7. DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x8553635 in /usr/bin/clickhouse
    26.843270 [ 39 ] {} <Fatal> BaseDaemon: 8. Poco::Util::Application::run() @ 0x11b7a313 in /usr/bin/clickhouse
    26.843284 [ 39 ] {} <Fatal> BaseDaemon: 9. DB::Server::run() @ 0x8545ebc in /usr/bin/clickhouse
    26.843299 [ 39 ] {} <Fatal> BaseDaemon: 10. mainEntryClickHouseServer(int, char**) @ 0x8544b25 in /usr/bin/clickhouse
    26.843313 [ 39 ] {} <Fatal> BaseDaemon: 11. main @ 0x84e1cbe in /usr/bin/clickhouse
    26.843331 [ 39 ] {} <Fatal> BaseDaemon: 12. __libc_start_main @ 0x270b3 in /usr/lib/x86_64-linux-gnu/libc-2.31.so
    26.843346 [ 39 ] {} <Fatal> BaseDaemon: 13. _start @ 0x84ac22e in /usr/bin/clickhouse
2021-01-31 11:29:46 +03:00
Amos Bird
18f3df31d5
Fix crash when pushing down predicates to union distinct subquery 2021-01-31 16:29:29 +08:00
Amos Bird
c39ee3f58c
Fix argMinMaxIf crash 2021-01-31 16:27:46 +08:00
Alexey Milovidov
5b7c437e6d Minor modification 2021-01-31 11:24:37 +03:00
alexey-milovidov
842c2c840c
Merge pull request #19773 from ClickHouse/tavplubix-patch-3
Fix stack overflow in FieldVisitorAccurateEquals
2021-01-31 11:09:41 +03:00
Alexey Milovidov
01a703ae50 Update test 2021-01-31 10:48:18 +03:00
Alexey Milovidov
d604cbc986 Maybe improve server latency 2021-01-31 10:41:24 +03:00
Alexey Milovidov
e23dc60e31 Fix UBSan report in GatherUtils 2021-01-31 10:12:17 +03:00
Alexey Milovidov
248540e58f Fix UBSan report in GatherUtils 2021-01-31 10:10:37 +03:00
Alexey Milovidov
40a356db74 Fix warning 2021-01-31 07:40:51 +03:00
Alexey Milovidov
0128d185ea Fix UBSan report in DateTimeAddInterval 2021-01-31 06:49:33 +03:00
alexey-milovidov
d93dad0ec3
Merge pull request #19722 from azat/background_message_broker_schedule_pool_size
Add separate pool for message brokers (RabbitMQ and Kafka)
2021-01-31 06:07:45 +03:00
alexey-milovidov
d0bd6af49d
Merge pull request #19824 from azat/tryLogCurrentException
Avoid losing exception messages in logs under high memory pressure
2021-01-31 06:05:55 +03:00
Alexey Milovidov
0fa5142715 Remove tons of garbage 2021-01-31 05:36:52 +03:00
Alexey Milovidov
5c718c8754 Merge branch 'master' into unicode-asan 2021-01-31 02:40:24 +03:00
alexey-milovidov
8ac39e7f56
Merge pull request #19791 from ClickHouse/format-readable-time-delta-ubsan
formatReadableTimeDelta: correctly output infinite values
2021-01-31 01:37:59 +03:00
Alexey Milovidov
30e1db7f47 Merge branch 'master' into azat-client-complete-error-codes 2021-01-31 00:01:47 +03:00
alexey-milovidov
d9e4ea8e58
Merge pull request #19853 from azat/bit-func-forbid-floats
Forbid bit functions for floats
2021-01-31 00:00:15 +03:00
bharatnc
e967ba5f3b try fix clang-11-darwin build 2021-01-30 12:12:38 -08:00
Maksim Kita
155f6c0eb5 Function reinterpretAs updated to support big integers 2021-01-30 22:56:23 +03:00
vdimir
5cb99ae699
Use offsets in FunctionIPv6StringToNum for copying ipv4 to buffer 2021-01-30 20:20:11 +03:00
Vitaly Baranov
95177dc0de Fix access to the key as an attribute in IPAddressDictionary. 2021-01-30 19:06:54 +03:00
Vitaly Baranov
7c8deae0e1 Fix starting the server with tables having columns' default expressions containing dictGet().
Allow getting return type of dictGet() without loading dictionary.
2021-01-30 19:06:48 +03:00
Vitaliy Zakaznikov
dc9c3c8514 Fixing styling errors.
Adding simple tests.
2021-01-30 09:00:42 -05:00
Nikolai Kochetov
f7dc83ae96
Merge pull request #19725 from ClickHouse/limit-push-down
Update QueryPlan tree optimization traverse.
2021-01-30 16:34:46 +03:00
Azat Khuzhin
502d981ab4 Use BinaryArithmeticOverloadResolver::valid_on_float_arguments for lcm/gcd 2021-01-30 09:12:31 +03:00
Azat Khuzhin
7da4083237 Forbid bit functions for floats
This will fix the following UB report [1]:

  "../src/Functions/bitAnd.cpp:24:61: runtime error: nan is outside the
range of representable values of type 'long' Received signal -3 Received
signal Unknown signal (-3)"

  [1]: https://clickhouse-test-reports.s3.yandex.net/19824/89c4055202b9d08459f90ee5791d4e3017b82fbf/fuzzer_ubsan/report.html#fail1
2021-01-30 09:12:31 +03:00
Alexey Milovidov
d44ce00391 Merge branch 'master' into format-readable-time-delta-ubsan 2021-01-30 07:28:38 +03:00
Alexander Kuzmenkov
5519e4c134 unbounded following frame end 2021-01-30 04:16:44 +03:00
Vitaliy Zakaznikov
3de4690450 Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into live_view_periodic_refresh 2021-01-29 19:57:13 -05:00
Alexander Kuzmenkov
f42aefc4a4
Merge pull request #19750 from excitoon-favorites/s3betterglobs
Used global region for accessing S3 if can't determine exactly
2021-01-29 23:44:14 +03:00
Alexander Kuzmenkov
98e88d7305
Merge pull request #19793 from excitoon-favorites/fixcompressions3
Fixed table function S3 `auto` compression mode
2021-01-29 23:42:05 +03:00
Azat Khuzhin
1fe003b85e Make system.asynchronous_metrics available just after start 2021-01-29 22:10:04 +03:00
Azat Khuzhin
89c4055202 Lock MEMORY_LIMIT_EXCEEDED error from tryLogCurrentException()
This will avoid hiding some exceptions in logs, when the server is under
high memory pressure (i.e. when any new allocation will lead to
MEMORY_LIMIT_EXCEEDED error).

This became more relevent after all memory allocations was tracked with
MemoryTracker, by falling back to total_memory_tracking, in #16121
2021-01-29 21:38:14 +03:00
alexey-milovidov
276e972166
Merge pull request #19789 from ClickHouse/fix-great-circle-angle
Fix mistake in greatCircleAngle
2021-01-29 21:35:26 +03:00
alexey-milovidov
d19feb724b
Merge pull request #19799 from CurtizJ/fix-uint8-filtering
Fix filtering by Uint8 greater than 127
2021-01-29 21:34:42 +03:00
Pavel Kruglov
78371e15dc Update test, reduce num_threads_for_lonely_parts if data is small 2021-01-29 21:00:08 +03:00
alesapin
f4236fd765 Fix style 2021-01-29 20:12:53 +03:00
alesapin
c373d92a80 Less strict check 2021-01-29 18:50:08 +03:00
Pavel Kruglov
71f4acd48b Use one pool for lonely parts, update tests 2021-01-29 17:30:14 +03:00
Ilya Yatsishin
a353020c54
Merge pull request #19804 from davenger/odbc_build_fix
Fix dependency on ODBC for Yandex internal build
2021-01-29 16:50:59 +03:00
alexey-milovidov
f8c897d308
Merge pull request #19798 from ClickHouse/test-connections
Add test script for #19794
2021-01-29 16:24:45 +03:00
alexey-milovidov
4cfcc18a7f
Merge pull request #19786 from ClickHouse/int-round-ubsan
Fix UBSan report in "round"
2021-01-29 14:59:12 +03:00
alexey-milovidov
0679d81c0d
Merge pull request #19788 from ClickHouse/array-enumerate-extended-bug
Fix trivial bug in arrayEnumerateUniq
2021-01-29 14:58:38 +03:00
Alexander Gololobov
0ee05d34fc Fix dependency on ODBC for Yandex internal build 2021-01-29 14:54:54 +03:00
Pavel Kruglov
a437ee4e31 Merge branch 'master' of github.com:ClickHouse/ClickHouse into select-final 2021-01-29 14:25:47 +03:00
Kruglov Pavel
caef103837
Merge branch 'master' into Add_IStoragePolicy_interface 2021-01-29 14:00:12 +03:00
Nikolai Kochetov
9f9b7fc3e2 Update ya.make 2021-01-29 13:05:21 +03:00
Maksim Kita
c7401f219f
Merge pull request #18236 from kitaisreal/dictionaries-support-for-nullable-and-array
[WIP] Dictionaries support for Array and Nullable
2021-01-29 12:02:23 +03:00
Anton Popov
031132038b fix filtering by uint8 greater than 127 2021-01-29 10:39:18 +03:00
Alexey Milovidov
5a92e633a1 Remove useless headers 2021-01-29 10:37:46 +03:00
Alexey Milovidov
bfcb12c2e9 Add test-connect tool 2021-01-29 09:13:43 +03:00
alexey-milovidov
76894ccb9f
Update greatCircleDistance.cpp 2021-01-29 08:52:52 +03:00
Alexey Milovidov
9477f8a8b1 Revert "Remove old non-automated test"
This reverts commit 217d05443a.
2021-01-29 08:27:58 +03:00
Vladimir Chebotarev
d729aacb09 Fixed table function S3 auto compression mode. 2021-01-29 07:54:52 +03:00
Alexey Milovidov
1e2669fd3c Fix error 2021-01-29 07:54:46 +03:00
Alexey Milovidov
f06bb78c5d Merge branch 'master' into unicode-asan 2021-01-29 05:18:29 +03:00
Alexey Milovidov
eee84eec79 formatReadableTimeDelta: correctly output infinite values 2021-01-29 05:14:15 +03:00
Alexey Milovidov
f4a05bd773 Fix mistake in greatCircleAngle 2021-01-29 05:05:46 +03:00
taiyang-li
35f8a0810a fix client bug while executing select 2021-01-29 09:59:26 +08:00
Alexey Milovidov
b3944006cb Fix trivial bug in arrayEnumerateUniq 2021-01-29 04:41:55 +03:00
alexey-milovidov
10160e5adf
Merge pull request #19767 from kitaisreal/low-cardinality-uuid-fix
LowCardinality UUID fix
2021-01-29 04:06:28 +03:00
Alexey Milovidov
eb0473c3f9 Fix UBSan report in "round" 2021-01-29 04:03:38 +03:00
alexey-milovidov
fa7a795c3a
Merge pull request #19588 from ClickHouse/disable-checksums-on-read
Allow to disable checksums on read
2021-01-29 02:37:26 +03:00
Alexander Kuzmenkov
2dd5062cc0 use current row as partition etalon 2021-01-28 23:46:22 +03:00
Alexander Kuzmenkov
09e192395a update comments and apply the setNeeded() advice from Nikolai 2021-01-28 23:39:27 +03:00