Commit Graph

106028 Commits

Author SHA1 Message Date
Alexander Tokmakov
8b13b85ea0
Merge pull request #44543 from ClickHouse/text_log_add_pattern
Add a column with a message pattern to text_log
2023-01-17 20:19:32 +03:00
Vitaly Baranov
1a680b0092 Abort multipart upload faster. 2023-01-17 18:00:11 +01:00
Vitaly Baranov
2de455367a Fix using std::ios_base::end in StdStreamFromReadBuffer::seekg(). 2023-01-17 17:56:14 +01:00
Igor Nikonov
0cfa08df7a Merge remote-tracking branch 'origin/master' into igor/remove_redundant_order_by 2023-01-17 16:28:17 +00:00
Yatsishin Ilya
5ae72fe711 Improve failed kafka startup logging 2023-01-17 16:25:05 +00:00
Igor Nikonov
9855504403 Rename source file according to implementation 2023-01-17 16:24:51 +00:00
alesapin
261dc06be9 Fix flaky ttl test 2023-01-17 17:08:32 +01:00
Dale Mcdiarmid
9c4d3e0ffb link docs to blogs 2023-01-17 15:38:10 +00:00
Nikita Mikhaylov
0fc755806e
One more attempt to fix race in TCPHandler (#45240) 2023-01-17 16:17:14 +01:00
Han Fei
8a74238fe0 improve 2023-01-17 15:47:52 +01:00
Kruglov Pavel
96bb99f864
Merge branch 'master' into tsv-csv-detect-header 2023-01-17 15:33:02 +01:00
Kruglov Pavel
582aa8b770
Merge pull request #45253 from Avogar/fix-s3-heap-use-after-free
Fix heap-use-after-free in reading from s3
2023-01-17 15:32:26 +01:00
HarryLeeIBM
e7add8218f Addressed more review comments and ClangTidy errors 2023-01-17 06:29:13 -08:00
Kruglov Pavel
4183f6082f
Fix special build 2023-01-17 15:18:39 +01:00
Azat Khuzhin
54fc6859ae Fix race in Distributed table startup
Before this patch it was possible to have multiple directory monitors
for the same directory, one from the INSERT context, another one on
storage startup().

Here are an example of logs for this scenario:

    2022.12.07 12:12:27.552485 [ 39925 ] {a47fcb32-4f44-4dbd-94fe-0070d4ea0f6b} <Debug> DDLWorker: Executed query: DETACH TABLE inc.dist_urls_in
    ...
    2022.12.07 12:12:33.228449 [ 4408 ] {20c761d3-a46d-417b-9fcd-89a8919dd1fe} <Debug> executeQuery: (from 0.0.0.0:0, user: ) /* ddl_entry=query-0000089229 */ ATTACH TABLE inc.dist_urls_in (stage: Complete)
    ... this is the DirectoryMonitor created from the context of INSERT for the old StoragePtr that had not been destroyed yet (becase of "was 1" this can be done only from the context of INSERT) ...
    2022.12.07 12:12:35.556048 [ 39536 ] {} <Trace> inc.dist_urls_in.DirectoryMonitor: Files set to 173 (was 1)
    2022.12.07 12:12:35.556078 [ 39536 ] {} <Trace> inc.dist_urls_in.DirectoryMonitor: Bytes set to 29750181 (was 71004)
    2022.12.07 12:12:35.562716 [ 39536 ] {} <Trace> Connection (i13.ch:9000): Connected to ClickHouse server version 22.10.1.
    2022.12.07 12:12:35.562750 [ 39536 ] {} <Debug> inc.dist_urls_in.DirectoryMonitor: Sending a batch of 10 files to i13.ch:9000 (0.00 rows, 0.00 B bytes).
    ... this is the DirectoryMonitor that created during ATTACH ...
    2022.12.07 12:12:35.802080 [ 39265 ] {} <Trace> inc.dist_urls_in.DirectoryMonitor: Files set to 173 (was 0)
    2022.12.07 12:12:35.802107 [ 39265 ] {} <Trace> inc.dist_urls_in.DirectoryMonitor: Bytes set to 29750181 (was 0)
    2022.12.07 12:12:35.834216 [ 39265 ] {} <Debug> inc.dist_urls_in.DirectoryMonitor: Sending a batch of 10 files to i13.ch:9000 (0.00 rows, 0.00 B bytes).
    ...
    2022.12.07 12:12:38.532627 [ 39536 ] {} <Trace> inc.dist_urls_in.DirectoryMonitor: Sent a batch of 10 files (took 2976 ms).
    ...
    2022.12.07 12:12:38.601051 [ 39265 ] {} <Error> inc.dist_urls_in.DirectoryMonitor: std::exception. Code: 1001, type: std::__1::__fs::filesystem::filesystem_error, e.what() = filesystem error: in file_size: No such file or directory ["/data6/clickhouse/data/inc/dist_urls_in/shard13_replica1/66827403.bin"], Stack trace (when copying this message, always include the lines below):
    ...
    2022.12.07 12:12:54.132837 [ 4408 ] {20c761d3-a46d-417b-9fcd-89a8919dd1fe} <Debug> DDLWorker: Executed query: ATTACH TABLE inc.dist_urls_in

And eventually both monitors (for a short period of time, one replaces
another) are trying to process the same batch (current_batch.txt), and
one of them fails because such file had been already removed.

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-01-17 14:51:00 +01:00
Igor Nikonov
6328e02f22 Fix: update input/output stream properties
After removing sorting step we need to update sorting properties of
input/ouput streams
2023-01-17 13:39:18 +00:00
Maksim Kita
d758d83937 Analyzer compound identifier typo correction fix 2023-01-17 14:29:48 +01:00
Antonio Andelic
ba363c141a Fix integration test 2023-01-17 13:12:52 +00:00
alesapin
b23ba36a4f
Merge pull request #45339 from ClickHouse/util-decompressor-wsl1
WSL1 inconsistency
2023-01-17 14:10:21 +01:00
Vitaly Baranov
8c5c423d67 Add test. 2023-01-17 13:11:24 +01:00
Sema Checherinda
35431e91e3
Merge pull request #45276 from ucasfl/avro-fix
Fix some avro reading bugs
2023-01-17 12:48:44 +01:00
Kseniia Sumarokova
5586f71950
Merge pull request #41231 from kssenii/minor-change-in-remote-read
Fix assertion in async read buffer from remote
2023-01-17 12:32:57 +01:00
kssenii
a657bbece7 Merge remote-tracking branch 'upstream/master' into slightly-better-output-for-glibc-check 2023-01-17 12:23:44 +01:00
kssenii
f3c1dc0c85 Slightly better output of glibc check 2023-01-17 12:17:57 +01:00
Maksim Kita
d6a36b1d16 Fixed code review issues 2023-01-17 12:02:50 +01:00
Sema Checherinda
2cd55bc398 fix/adjust tests in integration/test_partition 2023-01-17 12:02:18 +01:00
Maksim Kita
af716ca25d Fixed tests 2023-01-17 11:20:24 +01:00
Maksim Kita
250c93614c Revert "Revert "Validate function arguments in query tree"" 2023-01-17 11:20:24 +01:00
Vitaly Baranov
692065e5fe Fix backup if mutations got killed during the backup process. 2023-01-17 11:05:34 +01:00
Alexander Tokmakov
4e1cf778a6
Update clickhouse-test 2023-01-17 12:17:51 +03:00
Vitaly Baranov
0bea056241 Fix build. 2023-01-17 09:52:08 +01:00
Vitaly Baranov
1c845185c1 Split upload into parts of the same size for smooth uploading.
Correctly use AbortMultipleUpload request.
Support std::ios_base::end StdStreamBufFromReadBuffer::seekpos().
2023-01-17 09:35:43 +01:00
Vitaly Baranov
14a7ee8e26 Copy files to S3 during backup directly without using WriteBufferFromS3 to decrease memory consumption. 2023-01-17 09:35:41 +01:00
Vitaly Baranov
b13498d9ba
Merge pull request #45288 from vitlibar/fix-s3-requests-without-region
Fix s3 requests without region
2023-01-17 09:24:59 +01:00
Antonio Andelic
76eb3e3b3c Fix test 2023-01-17 07:34:39 +00:00
SmitaRKulkarni
bb4f251448
Merge branch 'master' into 42648_Support_scalar_subqueries_cache 2023-01-17 08:10:25 +01:00
Alexander Tokmakov
1fd8cf3d7f fix 2023-01-17 01:43:13 +01:00
Alexander Tokmakov
522686f78b less empty patterns 2023-01-17 01:19:44 +01:00
Kseniia Sumarokova
6a02bdc917
Update AsynchronousReadIndirectBufferFromRemoteFS.cpp 2023-01-17 00:37:47 +01:00
Alexander Tokmakov
870cfcc36a less fmt::runtime usages 2023-01-17 00:11:59 +01:00
Alexander Tokmakov
e7899825e6 save format strings for DB::Exceptions 2023-01-16 23:20:33 +01:00
Vitaly Baranov
9a52087989 More complex logic: GetObjectAttributes requests will be used
only if the endpoint is "*.amazonaws.com", otherwise HeadObject requests will be used.
2023-01-16 20:14:39 +01:00
Dmitry Novik
104e55bc22 Merge remote-tracking branch 'origin/master' into or-like-chain 2023-01-16 18:56:22 +00:00
Dmitry Novik
aa2a19eaa4 Use proper map for QueryTreeNode 2023-01-16 18:43:22 +00:00
Yakov Olkhovskiy
c8f635e40b WSL1 inconsistency 2023-01-16 18:32:41 +00:00
Dmitry Novik
72c1e0ae0f Rename test 2023-01-16 17:52:15 +00:00
Dmitry Novik
0aecc9ad80 Updates after the review 2023-01-16 17:43:36 +00:00
Vladimir C
b80ee8df50
Merge pull request #45256 from DanRoscigno/add-grace-hash-docs 2023-01-16 18:43:19 +01:00
Kruglov Pavel
e9d6590926
Merge branch 'master' into tsv-csv-detect-header 2023-01-16 17:50:24 +01:00
Kruglov Pavel
bdb3517512
Merge pull request #45231 from Avogar/json-tuples
Insert default values in case of missing tuple elements in JSONEachRow
2023-01-16 17:49:50 +01:00