Commit Graph

41469 Commits

Author SHA1 Message Date
Han Fei
07341a04fd
Merge pull request #49666 from hanfei1991/hanfei/regexp-dict-read
Support `dictionary` table function for `RegExpTreeDictionary`
2023-05-12 11:40:46 +02:00
Nikita Mikhaylov
66badcd59c
Merge pull request #49725 from vitlibar/incremental-backup-append-table-def
Fix writing appended files to incremental backups
2023-05-12 11:37:49 +02:00
Robert Schulze
922420420c
Merge pull request #49300 from ClickHouse/rs/functdocs
Introduce more fields for in-source function documentation
2023-05-12 11:36:04 +02:00
Vitaly Baranov
eb62030fa4 Fix assigning a setting to NULL in settings profile's definition. 2023-05-12 11:04:30 +02:00
Azat Khuzhin
fa2074e67b Use CLOCK_MONOTONIC_RAW over CLOCK_MONOTONIC on Linux (fixes non monotonic clock)
There is no bug in Linux, the issue that CLOCK_MONOTONIC returns values
less then previous calls likely happens due to adjtime(3) (NTP), since
CLOCK_MONOTONIC is affected by it, and I've seen lots of slight time
modifications due to NTP on the servers. And even on my desktop (I also
have NTP enabled):

    CLOCK_MONOTONIC:     189292.803 (2 days +  4h 34m 52s)
    CLOCK_MONOTONIC_RAW: 189290.016 (2 days +  4h 34m 50s)

However on Linux there is CLOCK_MONOTONIC_RAW, it is similar to
CLOCK_MONOTONIC, but does not affected by the adjtime(3).

About performance, it is the same:

    CLOCK_MONOTONIC 10e6:     real=0m0.191s user=0m0.190s sys=0m0.000s
    CLOCK_MONOTONIC_RAW 10e6: real=0m0.191s user=0m0.191s sys=0m0.000s

Ops/s:
- AMD Threadripper: 52.3e6
- Xeon Silver 4216 2.10: 46.5e6

Fixes: c5d631ca54
Fixes: #29811 (cc @tavplubix)
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-12 10:59:53 +02:00
Robert Schulze
d15f19912f
Merge pull request #49198 from ClibMouse/s390x_reinterpretas_fix
Fix reinterpretAs*() on big endian machines
2023-05-12 10:33:50 +02:00
Azat Khuzhin
9c42f7f113 Fix settings aliases in native protocol
The initial test (tests/queries/0_stateless/02539_settings_alias.sh)
works only because of the clickhouse-client, while in native protocol
aliases does not work.

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-12 05:56:32 +02:00
Azat Khuzhin
2c40dd6a4c Switch Block::NameMap to google::dense_hash_map over HashMap
Since HashMap creates 2^8 elements by default, while dense_hash_map
should be good here.

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-12 05:52:57 +02:00
Dmitry Novik
0c0ea7bfc0 Analyzer: apply _CAST to constants only once 2023-05-11 23:07:48 +00:00
Alexey Milovidov
76f7f5750d
Merge pull request #49799 from rschu1ze/demange
Typo: demange.cpp --> demangle.cpp
2023-05-12 02:01:49 +03:00
Vitaly Baranov
c4036b8361
Merge pull request #49381 from ClickHouse/user-grants-from-config
Specify grants for users in `users.xml`
2023-05-12 00:15:52 +02:00
Kseniia Sumarokova
f5b959624d
Merge pull request #49733 from ClickHouse/nickitat-patch-11
Do not allocate own buffer in CachedOnDiskReadBufferFromFile when `use_external_buffer == true`
2023-05-12 00:05:25 +02:00
Kseniia Sumarokova
41fa0a54e8
Merge pull request #49729 from kssenii/minor-change-move-log
Move assertions after logging
2023-05-11 23:47:26 +02:00
Robert Schulze
8ca804d40e
Typo: demange.cpp --> demangle.cpp 2023-05-11 21:32:12 +00:00
Vitaly Baranov
478140f8b4 Fix LimitSeekableReadBuffer. 2023-05-11 22:58:05 +02:00
Alexey Milovidov
ea979b40a9
Merge pull request #49717 from ClickHouse/disable-mmap-for-server
Disable mmap for StorageFile in clickhouse-server
2023-05-11 23:53:01 +03:00
Han Fei
ef74e64336 address comments 2023-05-11 22:18:08 +02:00
Suzy Wang
70db49cdeb
Merge branch 'master' into s390x_reinterpretas_fix 2023-05-11 14:41:57 -04:00
Robert Schulze
8997c6ef95
Merge pull request #49750 from ClickHouse/rs/msan-randomStringUTF8
Fix msan issue in randomStringUTF8(<uneven number>)
2023-05-11 18:49:12 +02:00
Kruglov Pavel
084a696b54
Merge branch 'master' into fiber-local-var 2023-05-11 17:55:25 +02:00
Vitaly Baranov
ec011b9113
Merge branch 'master' into user-grants-from-config 2023-05-11 17:08:06 +02:00
Anton Popov
292cfe12af
Merge branch 'master' into fix-unit-test 2023-05-11 16:56:21 +02:00
Anton Popov
d21dc829d9
Merge branch 'master' into add-forgotten-lock 2023-05-11 16:56:13 +02:00
Anton Popov
84aa97b738 fix arrayMap with array of tuples with single argument 2023-05-11 14:52:01 +00:00
Azat Khuzhin
e5c4eb35e8 Merge remote-tracking branch 'u/master' into build/llvm-16
* u/master:
  enable used flags's reinit only when the hash talbe rehash
  Fix build of libfiu on clang-16
  fix flaky test 02504_regexp_dictionary_ua_parser
  fix convertation
  Fix test that expected CH to apply a wrong optimization
  ActionsDAG: remove wrong optimization
2023-05-11 16:32:25 +02:00
Azat Khuzhin
00fdfa115f Suppress MSan warning in NgramDistanceImpl::unrollLowering()
NgramDistanceImpl::unrollLowering() relies on the fact that PODArray has
padding and it is OK to access more items.

Here is an MSan report:

    ==656==WARNING: MemorySanitizer: use-of-uninitialized-value
        0 0x557fd825485f in DB::NgramDistanceImpl<4ul, char8_t, false, true, false>::vectorConstant(DB::PODArray<char8_t, 4096ul, Allocator<false, false>, 63ul, 64ul> const&, DB::PODArray<unsigned long, 4096ul, Allocator<false, false>, 63ul, 64ul> const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, DB::PODArray<float, 4096ul, Allocator<false, false>, 63ul, 64ul>&) (/usr/bin/clickhouse+0x124d885f) (BuildId: 76773125d8739591c75d4f4d263a2ffe7ca96855)
        1 0x557fd824eb83 in DB::FunctionsStringSimilarity<DB::NgramDistanceImpl<4ul, char8_t, false, true, false>, DB::NameNgramSearchCaseInsensitive>::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName>> const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/usr/bin/clickhouse+0x124d2b83) (BuildId: 76773125d8739591c75d4f4d263a2ffe7ca96855)
        2 0x557fd50023b7 in DB::FunctionToExecutableFunctionAdaptor::executeImpl() const (/usr/bin/clickhouse+0xf2863b7) (BuildId: 76773125d8739591c75d4f4d263a2ffe7ca96855)

      Uninitialized value was stored to memory at
        0 0x557fd4f8da5a in __msan_memcpy (/usr/bin/clickhouse+0xf211a5a) (BuildId: 76773125d8739591c75d4f4d263a2ffe7ca96855)
        1 0x557fd8253803 in DB::NgramDistanceImpl<4ul, char8_t, false, true, false>::vectorConstant(DB::PODArray<char8_t, 4096ul, Allocator<false, false>, 63ul, 64ul> const&, DB::PODArray<unsigned long, 4096ul, Allocator<false, false>, 63ul, 64ul> const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, DB::PODArray<float, 4096ul, Allocator<false, false>, 63ul, 64ul>&) (/usr/bin/clickhouse+0x124d7803) (BuildId: 76773125d8739591c75d4f4d263a2ffe7ca96855)
        2 0x557fd824eb83 in DB::FunctionsStringSimilarity<DB::NgramDistanceImpl<4ul, char8_t, false, true, false>, DB::NameNgramSearchCaseInsensitive>::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName>> const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/usr/bin/clickhouse+0x124d2b83) (BuildId: 76773125d8739591c75d4f4d263a2ffe7ca96855)
        3 0x557fd50023b7 in DB::FunctionToExecutableFunctionAdaptor::executeImpl() const (/usr/bin/clickhouse+0xf2863b7) (BuildId: 76773125d8739591c75d4f4d263a2ffe7ca96855)

      Uninitialized value was stored to memory at
        0 0x557fd4f8da5a in __msan_memcpy (/usr/bin/clickhouse+0xf211a5a) (BuildId: 76773125d8739591c75d4f4d263a2ffe7ca96855)
        1 0x5580061699f5 in detail::memcpySmallAllowReadWriteOverflow15Impl(char*, char const*, long) build_docker/./src/Common/memcpySmall.h:42:13
        2 0x5580061699f5 in memcpySmallAllowReadWriteOverflow15(void*, void const*, unsigned long) build_docker/./src/Common/memcpySmall.h:57:5
        3 0x5580061699f5 in DB::ColumnString::replicate(DB::PODArray<unsigned long, 4096ul, Allocator<false, false>, 63ul, 64ul> const&) const build_docker/./src/Columns/ColumnString.cpp:462:13
        4 0x558005d3fae4 in DB::ColumnConst::convertToFullColumn() const build_docker/./src/Columns/ColumnConst.cpp:48:18

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-11 16:30:17 +02:00
Sergei Trifonov
1263c58f64
Merge branch 'master' into async-loader 2023-05-11 16:10:07 +02:00
Nikolay Degterinsky
3160483c17 Add query parameters to clickhouse-local 2023-05-11 12:56:59 +00:00
vdimir
fd7374fbc5
Analyzer: fix column not found for optimized prewhere with sample by 2023-05-11 12:38:46 +00:00
Eridanus
990c224540 improvement(parser): add support for size suffixes in quota creation
statement parameters

This commit adds support for creating quotas with size suffixes in the
parameter list of a quota creation statement. The parser now recognizes
size suffixes such as "KB", "MB", and "GB" and correctly converts them
to their corresponding values in bytes. This feature improves the
usability of the quota creation statement and makes it more flexible.
The commit also includes additional tests to ensure that the new syntax
is parsed correctly.
Attention: we did not support string literal with double like
execute_time = '1.5'
2023-05-11 20:04:53 +08:00
SmitaRKulkarni
9bf6175919
Merge pull request #47584 from aiven-sal/aiven-sal/having_pr
ActionsDAG: fix wrong optimization
2023-05-11 14:03:46 +02:00
Kseniia Sumarokova
183b4be796
Merge branch 'master' into nickitat-patch-11 2023-05-11 13:57:33 +02:00
Igor Nikonov
9865d7c7ec
Merge branch 'master' into enable-distinct-in-order 2023-05-11 13:49:55 +02:00
Han Fei
6b3160f7ce trivial change 2023-05-11 13:49:02 +02:00
Sema Checherinda
98769bb433
Merge pull request #49749 from CheSema/convertations_to_timespan
fix convertation
2023-05-11 12:11:16 +02:00
Robert Schulze
9db78792d0
Fix MsgPackRowInputFormat.cpp build 2023-05-11 10:00:32 +00:00
Robert Schulze
c2a4d89b6f
Fix style 2023-05-11 09:29:05 +00:00
Robert Schulze
1f3b1c47af
Merge branch 'master' into rs/msan-randomStringUTF8 2023-05-11 10:34:00 +02:00
Alexander Gololobov
1a91b6293d
Merge branch 'master' into fix_lwd_and_object 2023-05-11 09:39:57 +02:00
Sema Checherinda
8470aa8fbb
Merge branch 'master' into convertations_to_timespan 2023-05-11 08:24:40 +02:00
Sema Checherinda
66e3712dca
Merge branch 'master' into lost-blobs 2023-05-11 08:23:25 +02:00
Sema Checherinda
9724688608 rename field, do not fetch PreActive 2023-05-11 08:22:37 +02:00
Sema Checherinda
9ef14d5ed4
Merge branch 'master' into multi_part_upload 2023-05-11 08:21:02 +02:00
Alexey Milovidov
cfd3f76217
Merge branch 'master' into disable-mmap-for-server 2023-05-11 06:17:32 +03:00
lgbo-ustc
a07359fbe8 enable used flags's reinit only when the hash talbe rehash 2023-05-11 11:06:13 +08:00
Alexey Milovidov
91ffe8be73
Merge branch 'master' into build/llvm-16 2023-05-11 05:38:40 +03:00
Alexey Milovidov
3591eab432
Merge pull request #49762 from ClickHouse/fix-typo-10
Fix typo
2023-05-11 05:16:25 +03:00
Alexey Milovidov
aed031c3a3 Fix typo 2023-05-11 04:15:54 +02:00
Anton Popov
ff287c7bba add lock 2023-05-10 23:00:49 +00:00
Anton Popov
db52652337 fix unit test 2023-05-10 21:00:56 +00:00
Suzy Wang
d267c914c3
Merge branch 'master' into s390x_reinterpretas_fix 2023-05-10 16:08:50 -04:00
Suzy Wang
24b6ff47ac fix format and some more fix for fixedstring 2023-05-10 13:06:30 -07:00
Azat Khuzhin
d56e1423ef
Merge branch 'master' into build/llvm-16 2023-05-10 21:23:26 +02:00
Sema Checherinda
8bc9a32d19 fix special build 2023-05-10 18:45:59 +00:00
Sema Checherinda
60bf45f863 Update WriteBufferFromS3BufferAllocationPolicy.cpp 2023-05-10 18:31:58 +00:00
Sema Checherinda
cd449cca38 WriteBufferFromS3BufferAllocationPolicy for FixedSize and Exp policy 2023-05-10 18:31:58 +00:00
Sema Checherinda
7fbf87be17 rework WriteBufferFromS3, squashed 2023-05-10 18:31:47 +00:00
Robert Schulze
9795d5403f
Merge branch 'master' into rs/msan-randomStringUTF8 2023-05-10 20:16:49 +02:00
Alexander Gololobov
049ef9dda5
Merge branch 'master' into fix_lwd_and_object 2023-05-10 19:54:26 +02:00
Sema Checherinda
f2ad1122a1 fix convertation 2023-05-10 17:50:42 +00:00
Robert Schulze
374dbd9c39
Fix msan issue in randomStringUTF8(<uneven number>) 2023-05-10 17:49:23 +00:00
Kruglov Pavel
289af626ad
Merge branch 'master' into fiber-local-var 2023-05-10 18:21:46 +02:00
Sergei Trifonov
2169f077be
Merge branch 'master' into async-loader 2023-05-10 18:02:11 +02:00
Han Fei
2273884ded address comments 2023-05-10 17:42:08 +02:00
Alexey Milovidov
adad880c14
Merge pull request #49716 from CurtizJ/fix-sparse-short-circuit
Fix short circuit functions and mutations with sparse arguments
2023-05-10 18:11:33 +03:00
Alexey Milovidov
4a4eb5b171
Merge pull request #49660 from CurtizJ/fix-sparse-columns-reload
Fix reading from sparse columns after restart
2023-05-10 18:08:22 +03:00
Alexey Milovidov
33a58aacea
Merge pull request #49719 from ClickHouse/make-projections-non-experimental
Make projections production-ready
2023-05-10 18:07:02 +03:00
Azat Khuzhin
a0cc5b7e47 Merge remote-tracking branch 'u/master' into build/llvm-16 2023-05-10 16:28:36 +02:00
Alexander Gololobov
e6f4e5cd10 Ignore LWD column in checkPartDynamicColumns 2023-05-10 16:10:04 +02:00
Han Fei
d17aa828b3
Merge pull request #49361 from hanfei1991/hanfei/fiu
support named fault injection and add a simple test
2023-05-10 15:51:51 +02:00
Sergei Trifonov
6029bdeefa
Merge branch 'master' into async-loader 2023-05-10 15:04:49 +02:00
vdimir
1b7f54e886
Merge pull request #46467 from bigo-sg/first_value 2023-05-10 14:56:14 +02:00
Sergei Trifonov
0b2860d822
Merge branch 'master' into async-loader 2023-05-10 14:54:00 +02:00
avogar
a7aec49fbb Fix indents 2023-05-10 12:43:29 +00:00
Nikita Taranov
95bcccaf84
Do not allocate own buffer in CachedOnDiskReadBufferFromFile when use_external_buffer == true 2023-05-10 14:42:49 +02:00
avogar
10e6f5b59a Fix indents 2023-05-10 12:31:34 +00:00
avogar
0cf6b9f145 Inherit context from parent fiber 2023-05-10 12:27:13 +00:00
Roman Vasin
632c0eeefc
Add support of temporary tables in FROM part of ATTACH|REPLACE PARTITION FROM (#49436)
* Add temp tables after FROM

* Resolve works fine with temp and non-temp tables

* Add usage of temporary table in  00626_replace_partition_from_table test

* Update documentation

* Add tests for ReplicatedMergeTree

* Move tests into 02731_replace_partition_from_temporary_table
2023-05-10 15:25:12 +03:00
Han Fei
505d9be7b2 address comments 2023-05-10 13:56:17 +02:00
kssenii
acae08714b Move assertions after logging 2023-05-10 13:03:34 +02:00
Kseniia Sumarokova
1ea53b5885
Merge pull request #49690 from kssenii/add-logging-for-try-reserve
Add some logging
2023-05-10 12:59:56 +02:00
Nikolay Degterinsky
6b2daff663
Merge pull request #48880 from alekar/48716
Enhance usability of INTO OUTFILE clause for SELECT queries
2023-05-10 12:35:22 +02:00
Ilya Yatsishin
a4f7bfa62d
Merge pull request #49718 from ClickHouse/fix-typo-9
Fix typo
2023-05-10 12:32:37 +02:00
Azat Khuzhin
2f9a7cba8a Fix stack-use-after-scope in KafkaProducer::produce()
ASan report:

    ==1==ERROR: AddressSanitizer: stack-use-after-scope on address 0x7f7540186b20 at pc 0x55656ef458ad bp 0x7f754114acf0 sp 0x7f754114a4b8
    READ of size 2 at 0x7f7540186b20 thread T2 (TCPHandler)
        0 0x55656ef458ac in __asan_memcpy (/usr/bin/clickhouse+0x11b028ac) (BuildId: 6ba63057df561f6dc16fb8fd7623fd858bf327d1)
        1 0x55659f62daf8 in rd_kafka_msg_new00 build_docker/./contrib/librdkafka/src/rdkafka_msg.c:192:3
        2 0x55659f62daf8 in rd_kafka_msg_new0 build_docker/./contrib/librdkafka/src/rdkafka_msg.c:257:8
        3 0x55659f630635 in rd_kafka_producev build_docker/./contrib/librdkafka/src/rdkafka_msg.c:642:23
        4 0x55659f4a865c in cppkafka::Producer::do_produce() build_docker/./contrib/cppkafka/src/producer.cpp:128:19
        5 0x55659f4a8306 in cppkafka::Producer::produce() build_docker/./contrib/cppkafka/src/producer.cpp:69:5
        6 0x5565961e748c in DB::KafkaProducer::produce() build_docker/./src/Storages/Kafka/KafkaProducer.cpp:70:23
        7 0x5565962155b2 in DB::MessageQueueSink::consume(DB::Chunk) build_docker/./src/Storages/MessageQueueSink.cpp:64:23
        8 0x5565980b9e8e in DB::SinkToStorage::onConsume(DB::Chunk) build_docker/./src/Processors/Sinks/SinkToStorage.cpp:18:5

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-10 12:15:17 +02:00
Antonio Andelic
c6904805f4
Merge branch 'master' into fix-cnf-new-analyzer 2023-05-10 08:56:14 +02:00
Alexey Milovidov
0eae23ba2d
Merge pull request #49715 from ClickHouse/remove-unused-errorcodes
Remove not used ErrorCodes
2023-05-10 06:43:16 +03:00
Alexey Milovidov
8a6e07f0ea Make projections production-ready 2023-05-10 03:35:13 +02:00
Alexey Milovidov
56ea17c922 Fix typo 2023-05-10 03:21:36 +02:00
Alexey Milovidov
8a23d8b389 Disable mmap for server 2023-05-10 03:17:57 +02:00
Alexey Milovidov
a2c4b8e23d Disable mmap for server 2023-05-10 03:16:52 +02:00
robot-clickhouse-ci-2
c698d2af99
Merge pull request #49702 from ClickHouse/nickitat-patch-11
Enable `do_not_evict_index_and_mark_files` by default
2023-05-10 02:26:38 +02:00
Anton Popov
862008da0d
Merge pull request #49663 from CurtizJ/fix-race-context-copy
Fix race in `Context::createCopy`
2023-05-10 02:11:35 +02:00
Anton Popov
8ff5fda628 fix short curcuit function with sparse arguments 2023-05-09 23:54:13 +00:00
Alexey Milovidov
f20a1893f5
Merge branch 'master' into enable-distinct-in-order 2023-05-10 02:08:32 +03:00
Sergei Trifonov
dc5664f36a
Merge branch 'master' into remove-unused-errorcodes 2023-05-10 00:49:55 +02:00
Anton Popov
996fcfe120 fix column ttl with sparse columns 2023-05-09 21:37:43 +00:00
alekar
67ad681e41
Merge branch 'master' into 48716 2023-05-09 14:34:32 -07:00
Suzy Wang
1b21f13605 ip encoding fix 2023-05-09 13:57:22 -07:00
kssenii
e35c669892 Fix 2023-05-09 22:51:47 +02:00
alekar
605991d4d5
Merge branch 'master' into 48716 2023-05-09 13:38:11 -07:00
Suzy Wang
ce471a2e8b Updated code as suggested 2023-05-09 13:31:54 -07:00
Azat Khuzhin
9b3bcd0870 Fix stack-use-after-scope in gtest_resource_manager_static
Reordering of the static variables should be enough to fix this:

    [ RUN      ] IOResourceStaticResourceManager.Prioritization
    =================================================================
    ==13==ERROR: AddressSanitizer: stack-use-after-scope on address 0x7f7d8d621970 at pc 0x5636b80dcbb2 bp 0x7f7c48e47dd0 sp 0x7f7c48e47dc8
    READ of size 8 at 0x7f7d8d621970 thread T3975 (ThreadPool)
        #0 0x5636b80dcbb1 in IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_1::operator()(long) const build_docker/./src/IO/Resource/tests/gtest_resource_manager_static.cpp:78:13
        #1 0x5636b80dcbb1 in IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0::operator()() const build_docker/./src/IO/Resource/tests/gtest_resource_manager_static.cpp:95:21
        #2 0x5636b80dcbb1 in decltype(std::declval<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&>()()) std::__1::__invoke[abi:v15000]<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&) build_docker/./contrib/llvm-project/libcxx/include/__functional/invoke.h:394:23
        #3 0x5636b80dcbb1 in decltype(auto) std::__1::__apply_tuple_impl[abi:v15000]<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&, std::__1::tuple<>&>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&, std::__1::tuple<>&, std::__1::__tuple_indices<>) build_docker/./contrib/llvm-project/libcxx/include/tuple:1789:1
        #4 0x5636b80dcbb1 in decltype(auto) std::__1::apply[abi:v15000]<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&, std::__1::tuple<>&>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&, std::__1::tuple<>&) build_docker/./contrib/llvm-project/libcxx/include/tuple:1798:1
        #5 0x5636b80dcbb1 in ThreadFromGlobalPoolImpl<true>::ThreadFromGlobalPoolImpl<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&&)::'lambda'()::operator()() build_docker/./src/Common/ThreadPool.h:228:13
        #6 0x5636b80dcbb1 in decltype(std::declval<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0>()()) std::__1::__invoke[abi:v15000]<ThreadFromGlobalPoolImpl<true>::ThreadFromGlobalPoolImpl<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&&)::'lambda'()&>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&&) build_docker/./contrib/llvm-project/libcxx/include/__functional/invoke.h:394:23
        #7 0x5636b80dcbb1 in void std::__1::__invoke_void_return_wrapper<void, true>::__call<ThreadFromGlobalPoolImpl<true>::ThreadFromGlobalPoolImpl<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&&)::'lambda'()&>(ThreadFromGlobalPoolImpl<true>::ThreadFromGlobalPoolImpl<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&&)::'lambda'()&) build_docker/./contrib/llvm-project/libcxx/include/__functional/invoke.h:479:9
        #8 0x5636b80dcbb1 in std::__1::__function::__default_alloc_func<ThreadFromGlobalPoolImpl<true>::ThreadFromGlobalPoolImpl<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&&)::'lambda'(), void ()>::operator()[abi:v15000]() build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:235:12
        #9 0x5636b80dcbb1 in void std::__1::__function::__policy_invoker<void ()>::__call_impl<std::__1::__function::__default_alloc_func<ThreadFromGlobalPoolImpl<true>::ThreadFromGlobalPoolImpl<IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0>(IOResourceStaticResourceManager_Prioritization_Test::TestBody()::$_0&&)::'lambda'(), void ()>>(std::__1::__function::__policy_storage const*) build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:716:16
        #10 0x5636ea219310 in std::__1::__function::__policy_func<void ()>::operator()[abi:v15000]() const build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:848:16
        #11 0x5636ea219310 in std::__1::function<void ()>::operator()() const build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:1187:12
        #12 0x5636ea219310 in ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) build_docker/./src/Common/ThreadPool.cpp:416:13
        #13 0x5636ea2258ac in void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, long, std::__1::optional<unsigned long>, bool)::'lambda0'()::operator()() const build_docker/./src/Common/ThreadPool.cpp:180:73
        #14 0x5636ea2258ac in decltype(std::declval<void>()()) std::__1::__invoke[abi:v15000]<void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, long, std::__1::optional<unsigned long>, bool)::'lambda0'()>(void&&) build_docker/./contrib/llvm-project/libcxx/include/__functional/invoke.h:394:23
        #15 0x5636ea2258ac in void std::__1::__thread_execute[abi:v15000]<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct>>, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, long, std::__1::optional<unsigned long>, bool)::'lambda0'()>(std::__1::tuple<void, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, long, std::__1::optional<unsigned long>, bool)::'lambda0'()>&, std::__1::__tuple_indices<>) build_docker/./contrib/llvm-project/libcxx/include/thread:284:5
        #16 0x5636ea2258ac in void* std::__1::__thread_proxy[abi:v15000]<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct>>, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, long, std::__1::optional<unsigned long>, bool)::'lambda0'()>>(void*) build_docker/./contrib/llvm-project/libcxx/include/thread:295:5
        #17 0x7f7d8fcf1608 in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x8608) (BuildId: 7b4536f41cdaa5888408e82d0836e33dcf436466)
        #18 0x7f7d8fc16132 in __clone (/lib/x86_64-linux-gnu/libc.so.6+0x11f132) (BuildId: 1878e6b475720c7c51969e69ab2d276fae6d1dee)

    Address 0x7f7d8d621970 is located in stack of thread T0 at offset 368 in frame
        #0 0x5636b80d9bef in IOResourceStaticResourceManager_Prioritization_Test::TestBody() build_docker/./src/IO/Resource/tests/gtest_resource_manager_static.cpp:46

      This frame has 10 object(s):
        [32, 36) 'requests_per_thead' (line 48)
        [48, 208) 't' (line 49)
        [272, 296) 'ref.tmp' (line 51)
        [336, 352) 'last_priority' (line 74)
        [368, 376) 'check' (line 75) <== Memory access at offset 368 is inside this variable
        [400, 424) 'name' (line 83)
        [464, 512) 'ref.tmp13' (line 87)
        [544, 560) 'c' (line 101)
        [576, 600) 'ref.tmp32' (line 101)
        [640, 664) 'ref.tmp41' (line 102)

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-09 21:32:13 +02:00
Azat Khuzhin
d8dd50a9c6 Fix misc-misplaced-const clang-tidy warning
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-09 21:27:21 +02:00
Azat Khuzhin
0610865811 Fix readability-redundant-string-cstr clang-tidy warning
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-09 21:22:05 +02:00
Azat Khuzhin
d03ae2abfa Fix modernize-loop-convert clang-tidy warning
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-09 21:19:37 +02:00
avogar
930c8c3043 Use own fiber local implementation 2023-05-09 18:56:09 +00:00
Azat Khuzhin
051d0e57ff Suppress bugprone-standalone-empty in DatabaseMySQL
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-09 20:47:52 +02:00
Azat Khuzhin
be39e8e566 Merge remote-tracking branch 'u/master' into build/llvm-16
Conflicts:
	docker/test/codebrowser/Dockerfile
2023-05-09 20:40:43 +02:00
Azat Khuzhin
833652b7c9 Revert "Suppress clang-analyzer-cplusplus.NewDelete in MsgPackRowInputFormat"
Let's try to revert this quirk during upgrading to clang 16.

This reverts commit c1e70169d2.
2023-05-09 20:36:39 +02:00
Han Fei
ddce47f79e refine table source for regexp tree dictionary 2023-05-09 20:17:54 +02:00
kssenii
c20aa0786d More logging 2023-05-09 19:29:57 +02:00
kssenii
abc909fb21 Merge remote-tracking branch 'upstream/master' into add-logging-for-try-reserve 2023-05-09 19:13:58 +02:00
kssenii
13b77f1dac Fix 2023-05-09 19:13:39 +02:00
Anton Popov
d88224dc43 fix build 2023-05-09 16:30:43 +00:00
Nikita Taranov
7cd6db3fb3
Enable do_not_evict_index_and_mark_files by default 2023-05-09 18:04:47 +02:00
Dmitry Novik
1da54538f1
Merge branch 'master' into fix-cnf-new-analyzer 2023-05-09 17:31:05 +02:00
kssenii
75aa775d2b Add logging 2023-05-09 15:58:20 +02:00
serxa
459181568c remove not used ErrorCodes 2023-05-09 11:54:25 +00:00
alesapin
277b42451e
Merge branch 'master' into fix_database_replica_recovery 2023-05-09 13:06:45 +02:00
Azat Khuzhin
a794177dc3 Use __powerpc64__ over __ppc64__ (clang 16 stops declaring __ppc64__)
From the release notes [1]:

    To match GCC, __ppc64__ is no longer defined on PowerPC64 targets. Use __powerpc64__ instead.

  [1]: https://releases.llvm.org/16.0.0/tools/clang/docs/ReleaseNotes.html

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-05-09 12:20:50 +02:00
Sergei Trifonov
4f9d443226
Merge branch 'master' into async-loader 2023-05-09 12:04:23 +02:00
vdimir
6bb552377f
Merge pull request #49085 from ClibMouse/saveIntervals 2023-05-09 11:33:05 +02:00
Kseniia Sumarokova
abde991cc4
Merge pull request #49675 from ClickHouse/cache-cleanup-after-locking-rework
Some cache cleanup after rework locking
2023-05-09 11:29:45 +02:00
Robert Schulze
3ab4a46c7b
Merge pull request #49658 from saitama951/clickhouse
Fix Optimization Issue for T64 library for S390x
2023-05-09 09:11:09 +02:00
Robert Schulze
d1429630f5
Merge pull request #49651 from jinjunzh/iaadeflate_idxd_config_amend
add missing idxd-config module for qpl-deflate codec
2023-05-09 08:32:45 +02:00
Alexey Milovidov
3556c26075
Merge pull request #49434 from ClickHouse/ins
Make INSERT do more things in parallel to avoid getting bottlenecked on one thread
2023-05-09 08:10:15 +03:00
Alexey Milovidov
a8bdb20fc4
Merge pull request #48787 from ClickHouse/background-memory-tracker
Add MemoryTracker for the background tasks [Resubmit]
2023-05-09 07:58:36 +03:00
Alexey Milovidov
9a73a04fe3
Merge pull request #42587 from ClickHouse/compress-marks-primary-key-by-default
Compress marks and primary key by default
2023-05-09 06:43:10 +03:00
Alexey Milovidov
dda6e9175c
Merge pull request #49647 from ClickHouse/optimize-opentelemetry-span-log
Optimize `opentelemetry_span_log`
2023-05-09 06:40:49 +03:00
Han Fei
64b67b9a37 Merge branch 'master' into hanfei/fiu 2023-05-09 01:14:30 +02:00
Kseniia Sumarokova
bfe9537012
Merge pull request #49426 from kssenii/remove-dependency-from-context
Remove dependency from DB::Context in remote/cache readers
2023-05-08 23:25:12 +02:00
Han Fei
82ce47ce56 address comments 2023-05-08 23:02:36 +02:00
Igor Nikonov
903021e896 Fix review comment 2023-05-08 18:29:47 +00:00
Igor Nikonov
bb68a1582c Enable distinct in order after fix #49636 2023-05-08 18:12:22 +00:00
Alexander Tokmakov
7250e7fec8 correctly update log pointer during replica recovery 2023-05-08 19:58:43 +02:00
Igor Nikonov
e7fff74797 Cleanup 2023-05-08 17:45:42 +00:00
Han Fei
80692caa4c
Update src/Access/Common/AccessType.h
Co-authored-by: Sergei Trifonov <svtrifonov@gmail.com>
2023-05-08 19:33:53 +02:00
avogar
c961e3706e Clean up 2023-05-08 16:52:57 +00:00
larryluogit
2341c5e6a3
Merge branch 'master' into saveIntervals 2023-05-08 12:49:21 -04:00
Igor Nikonov
8bc04d5fa8
Merge pull request #49636 from ClickHouse/fix-distinct-in-order-bug-49622
Fix: DISTINCT in order with zero values in non-sorted columns
2023-05-08 18:42:38 +02:00
avogar
b320527158 Fix assert in SpanHolder::finish() with fibers 2023-05-08 16:33:39 +00:00
Han Fei
71c96ceb61
Update src/Interpreters/ExternalDictionariesLoader.h 2023-05-08 16:21:42 +02:00
Han Fei
72fc567d4a
Merge branch 'master' into hanfei/regexp-dict-read 2023-05-08 16:20:12 +02:00
Han Fei
92e57817a2 Support dictionary table function for RegExpTreeDictionary 2023-05-08 16:14:08 +02:00
Alexey Milovidov
a0f5ce5d6e
Merge branch 'master' into optimize-opentelemetry-span-log 2023-05-08 16:40:37 +03:00
Anton Popov
713ffb3bda fix race in Context::createCopy 2023-05-08 13:22:31 +00:00
Alexander Tokmakov
5629d73bdb
Merge pull request #49560 from ClickHouse/fix_dictionaries_loading_order
Fix dictionaries loading order
2023-05-08 16:07:40 +03:00
Smita Kulkarni
49ecba63af Removed setStageForCluster and added option all_hosts to set stage for cluster 2023-05-08 14:51:04 +02:00
Alexander Tokmakov
14dc7d988f fix 2023-05-08 14:49:45 +02:00
Smita Kulkarni
f20901d9d3 Merge branch 'master' into Follow_up_Backup_Restore_concurrency_check_node_2 2023-05-08 13:53:19 +02:00